Hi,
I am getting the following syntax error, while parsing the xml mapping file with hibernate 3.2
Code:
The content of element type "hibernate-mapping" must match "(meta*,typedef*,import*,(class|subclass|joined-subclass|union-subclass)*,resultset*,(query|sql-query)*,filter-def*,database-object*)"
I can not find out what is missing or what is wrong with my mapping.
Code:
<?xml version="1.0"?>
<!DOCTYPE hibernate-mapping PUBLIC
"-//Hibernate/Hibernate Mapping DTD 3.0//EN"
"http://hibernate.sourceforge.net/hibernate-mapping-3.0.dtd">
<hibernate-mapping package="de.tds.ito.visualsolariszone">
<filter-def name="theFilter">
<filter-param name="theStartTimestamp" type="timestamp"/>
<filter-param name="theStopTimestamp" type="timestamp"/>
<filter-param name="theZoneId" type="integer"/>
<filter-param name="theZoneName" type="string"/>
</filter-def>
<class name="ZoneInfoBean" table="ZONE_INFO_BEAN">
<id name="pid" >
<generator class="native"></generator>
</id>
<property name="calendarTimeStamp" type="timestamp"></property>
<property name="zoneid"></property>
<property name="zoneName"></property>
<property name="cpuPercent"></property>
<property name="cpuShares"></property>
<property name="memPercent"></property>
<property name="memRss"></property>
<property name="memSize"></property>
<property name="numProcs"></property>
<property name="selected"></property>
<property name="timeString"></property>
<property name="valid"></property>
<property name="zoneCfgXml"></property>
<property name="zoneHomeDirectory"></property>
<property name="zoneStateString"></property>
<filter name="theFilter" condition="(calendarTimeStamp BETWEEN :theStartTimestamp AND :theStopTimestamp) AND zoneid = :theZoneId"></filter>
<filter name="theFilter" condition="(calendarTimeStamp BETWEEN :theStartTimestamp AND :theStopTimestamp) AND zoneName = :theZoneName"></filter>
<filter name="theFilter" condition="zoneid = :theZoneId"></filter>
<filter name="theFilter" condition="zoneName = :theZoneName"></filter>
</class>
</hibernate-mapping>
The Application is quite simple, the described table is the only one I need.
Lukas