|
Hibernate example source code file (mapping.hbm.xml)
The Hibernate mapping.hbm.xml source code<?xml version="1.0"?> <!DOCTYPE hibernate-mapping SYSTEM "http://www.hibernate.org/dtd/hibernate-mapping-3.0.dtd"> <hibernate-mapping package="org.hibernate.test.unionsubclass.alias"> <class name="Seller"> <composite-id class="PersonID" name="id"> <key-property column="NR_RZBK" name="num" /> <key-property column="TXT_OID" name="name" /> </composite-id> <set cascade="persist, merge, save-update" inverse="true" lazy="false" name="buyers"> <key> <column name="NR_RZBK" /> <column name="TXT_OID_TESTB" /> </key> <one-to-many class="CarBuyer" /> </set> </class> <class abstract="true" name="Customer"> <composite-id class="PersonID" name="id"> <key-property column="NR_RZBK" name="num" /> <key-property column="TXT_OID" name="name" /> </composite-id> <union-subclass name="CarBuyer"> <property column="PID" name="pid" update="false" /> <property column="TXT_OID_TESTB" name="sellerName" /> <many-to-one cascade="persist, merge, save-update" class="Seller" insert="false" name="seller" update="false"> <column name="NR_RZBK" /> <column name="TXT_OID_TESTB" /> </many-to-one> </union-subclass> </class> </hibernate-mapping> Other Hibernate examples (source code examples)Here is a short list of links related to this Hibernate mapping.hbm.xml source code file: |
... this post is sponsored by my books ... | |
#1 New Release! |
FP Best Seller |
Copyright 1998-2021 Alvin Alexander, alvinalexander.com
All Rights Reserved.
A percentage of advertising revenue from
pages under the /java/jwarehouse
URI on this website is
paid back to open source projects.