Greetings,
I have a Java class and I've marked all attributes except one with the @Column annotation so that hibernate can map them. I don't want that particular attribute to be stored in the DB.
I've set everything properly, in fact, if I comment out that attribute Hibernate works fine.
How can I tell Hibernate to ignore that attribute when creating the DB tables and performing save, update, etc.. operations?
Here's a sample of what I'd like to do:
Code:
@Entity
@Table(name = "name")
public class Name implements Serializable{
@Column(name="field1")
private String field1;
@DO_NOT_MAP_THIS
private String field2;
}
Thank you
ps: couldn't search the forum as "my query contained common words"
edit: solved with @Transient