@org.hibernate.annotations.Index

hibernate buch cover klein

Extract of the annotation reference in the Hibernate Developer Guide by example

Extensive, easy-to-follow introduction to Hibernate 3 including complete working examples. Integration of Hibernate with other technologies like Spring, EJB3, Struts and JavaServer Faces (MyFaces) is explained.

It is available as PDF in English language.
A German paper book was published by the Galileo Verlag.

Get more information.

@org.hibernate.annotations.Index(

Hibernate Erweiterung zu EJB 3, definiert einen Index

name = "forestidx",

Name des Index

columnNames = {"colA","colB"}

Databankspalten, die im Index enthalten sind

)


@Entity()

@javax.persistence.Table(name = "tableName",
uniqueConstraints = { @UniqueConstraint(columnNames = { "unique_column" }) })

@org.hibernate.annotations.Table(appliesTo = "tableName",
indexes = { @Index(name = "forestidx", columnNames = { "indexedcolumn" }) })

public class Garden implements Serializable {