java - What is the equivalent of @OneToOne(optional=false) in hbm.xml files? -
we use hibernate 3 hbm.xml files. recently, found one-to-one association (based on primary keys) not loaded lazily , thus, making memory issues. after little search, found solution annotation-based hibernate configurations: since other side of association present, needed add @onetoone(optional=false) before corresponding property in java class.
the problem have not used annotations! tried add attribute optional="false" in tag, resulted in xml parsing exceptions. looking equivalent of @onetoone(optional=false) in hbm.xml files.
based on source, looks constrained=true
equivalent.
Comments
Post a Comment