Tuesday, May 5, 2009

Hibernate mapping for trigger populated columns

Suppose you have table columns whose values are populated by triggers. For example, createdBy, updatedBy, createdDate, & updatedDate. The following Hibernate mapping indicates that these columns are managed by database. The mapping is also "trigger friendly" - Hibernate will retrieve the values automatically. There is no need for an extra explicit SELECT.

No comments:

Post a Comment