144 CHAPTER 7 n CREATING MAPPINGS WITH HIBERNATE (Cpanel web hosting)

144 CHAPTER 7 n CREATING MAPPINGS WITH HIBERNATE XML FILES CHAPTER 7 n CREATING MAPPINGS WITH HIBERNATE XML FILES Table 7-3. Continued Attribute Values Default Description check Defines an additional row-level check constraint, effectively adding this as a SQL CHECK( … ) clause during table generation (for example, check=”salary < 1000000"). discriminator-value A value used to distinguish between otherwise identical subclasses of a common type persisted to the same table. is null and is not null are permissible values. To distinguish between a Cat and a Dog derivative of the Mammal abstract class, for example, you might use discriminator values of C and D, respectively. dynamic-insert true, false false Indicates whether all columns should appear in INSERT statements. If the attribute is set to true, null columns will not appear in generated INSERT commands. On very wide tables, this may improve performance; but because insert statements are cached, dynamic-insert can easily produce a performance hit. dynamic-update true, false false Indicates whether all columns should appear in UPDATE statements. If the attribute is set to true, unchanged columns will not appear in generated UPDATE commands. As with dynamic- insert, this can be tweaked for performance reasons. You must enable dynamic-update if you want to use version- based optimistic locking (discussed in Appendix A). entity-name The name of the entity to use in place of the class name (therefore required if dynamic mapping is used). lazy true, false Used to disable or enable lazy fetching against the enclosing mapping s default. mutable true, false true Used to flag that a class is immutable (allowing Hibernate to make some performance optimizations when dealing with these classes). name The fully qualified Java name, or optionally unqualified if the element declares a package attribute, of the class (or interface) that is to be made persistent. node Specifies the name of the XML element or attribute that should be used by the XML relational persistence features.
Note: In case you are looking for affordable and reliable webhost to host and run your business application check Vision php5 hosting services

Leave a Reply