java - what happens in hibernate if i give a column tag for a transient variable? -



java - what happens in hibernate if i give a column tag for a transient variable? -

what happens in hibernate if give column tag transient variable?

@table(name="team") public class team extends baseobject implements serializable { @id @generatedvalue(strategy=generationtype.auto) private long id; @column(length=50) private string name; @column(length=10) private string code; @column(name = "agency_id") private long agencyid; @column(name = "agency_name") private transient string agencyname; }

field not persistent. not field value database, changes not commited.

jsr 220 specification

if entity has field-based access, persistence provider runtime accesses instance variables directly. non-transient instance variables not annotated transient annotation persistent.

java hibernate transient

Comments

Popular posts from this blog

formatting - SAS SQL Datepart function returning odd values -

c++ - Apple Mach-O Linker Error(Duplicate Symbols For Architecture armv7) -

php - Yii 2: Unable to find a class into the extension 'yii2-admin' -