~ubuntu-branches/ubuntu/wily/libhibernate3-java/wily-proposed

« back to all changes in this revision

Viewing changes to test/org/hibernate/test/filter/Product.hbm.xml

  • Committer: Bazaar Package Importer
  • Author(s): Torsten Werner
  • Date: 2007-10-14 14:43:34 UTC
  • Revision ID: james.westby@ubuntu.com-20071014144334-eamc8i0q10gs1aro
Tags: upstream-3.2.5
ImportĀ upstreamĀ versionĀ 3.2.5

Show diffs side-by-side

added added

removed removed

Lines of Context:
 
1
<?xml version="1.0"?>
 
2
<!DOCTYPE hibernate-mapping
 
3
        SYSTEM
 
4
        "http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd" >
 
5
 
 
6
<hibernate-mapping package="org.hibernate.test.filter">
 
7
 
 
8
    <class name="Product" table="PRODUCT">
 
9
        <id name="id" column="PROD_ID" >
 
10
                <generator class="native"/>
 
11
        </id>
 
12
 
 
13
        <property name="name" type="string"/>
 
14
            <property name="stockNumber" column="STOCK_NUM" type="int"/>
 
15
 
 
16
            <property name="effectiveStartDate" column="eff_start_dt" type="java.util.Date"/>
 
17
            <property name="effectiveEndDate" column="eff_end_dt" type="java.util.Date"/>
 
18
 
 
19
            <set cascade="none" inverse="true" name="orderLineItems">
 
20
                    <key column="PROD_ID"/>
 
21
                    <one-to-many class="LineItem"/>
 
22
            </set>
 
23
 
 
24
            <set cascade="all" inverse="false" name="categories" fetch="join" table="PROD_CAT" >
 
25
                    <key column="PROD_ID"/>
 
26
                    <many-to-many class="Category" column="CAT_ID" fetch="join" >
 
27
                    <filter name="effectiveDate" condition=":asOfDate BETWEEN eff_start_dt and eff_end_dt"/>
 
28
                            <filter name="cat" condition="CAT_ID = :catId"/> 
 
29
            </many-to-many>
 
30
            </set>
 
31
 
 
32
            <filter name="effectiveDate" condition=":asOfDate BETWEEN eff_start_dt and eff_end_dt"/>
 
33
 
 
34
        </class>
 
35
 
 
36
</hibernate-mapping>
 
 
b'\\ No newline at end of file'