문제

i migrated from hibernate 4.2.x to 4.3.x and now the @Index annotation is deprecated. I used to use

@Basic
@Column(length = 2000)
@Index(name = "siteOrigin_idx")
private String siteOrigin;

to index the strings. I simply don't get how to enable indexing in hibernate 4.3+.

도움이 되었습니까?

해결책

Since Hibernate 4.3 implements JPA 2.1, you're supposed to use @Index annotation from JPA 2.1 now.

라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top