A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
Meteor in Action
this week in the
Object Relational Mapping
Hibernate annotation: exclude a field
Joined: Dec 23, 2003
Mar 11, 2010 17:45:14
In hibernate annotation, a class is declared as org.hibernate.annotations.Entity, how can I exclude a field so that it will NOT be mapped in database ? In traditional way, that is easy, we don't need write that field in hbm xml file.
Joined: Jul 30, 2008
Mar 11, 2010 21:50:22
You can use @Transient for that field, So it will not persist in to database.
I agree. Here's the link:
subject: Hibernate annotation: exclude a field
Persistence Unit: Unable to build EntityManagerFactory
how to exclude a class member from hibernate mapping?
I am getting null value for particular column, while loading the object.
how to use hibernate annotations with abstract methods
Query fields for Annotations
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2015