Hi,
i'd like to know if it's possible (or better how) i can create a Criteria,
where i can select a List of "Reisepaket" where the size of the List
"events" is equal 'x' (e.g. x = 0).
I searched Documentation and Forum here, but couldn't find any
hint.
Greets,
ap0
Hibernate version: 2.1.7c
Mapping documents:
Code:
<?xml version="1.0"?>
<!DOCTYPE hibernate-mapping PUBLIC
"-//Hibernate/Hibernate Mapping DTD//EN"
"http://hibernate.sourceforge.net/hibernate-mapping-2.0.dtd">
<hibernate-mapping package="de.fh_brs.travelution.businessobjects">
<class name="Reisepaket" table="reisepaket">
<id name="id" type="long" column="paket_id">
<generator class="identity"/>
</id>
<component name="reisewunsch" class="Reisewunsch">
<property name="ziel" type="string" not-null="true"/>
<property name="anfang" type="date" not-null="true"/>
<property name="ende" type="date" not-null="true"/>
<property name="beschreibung" type="text"/>
</component>
<many-to-one name="kunde" class="Kunde" not-null="true"/>
<many-to-one name="agent" class="Agent"/>
<many-to-one name="transfer" class="Transfer"/>
<list name="events">
<key column="events"/>
<index column="pos_events"/>
<composite-element class="Event"/>
</list>
<property name="istGebucht" type="true_false" not-null="true"/>
</class>
</hibernate-mapping>
Name and version of the database you are using:
MySQL 4.0.20a