I checked for this error which other people have reported. In each case, there really was something wrong with their hbm file. However, in my case, I know the hbm file is good, because, I used it without error in a different execution path. This time I am using ant to do SchemaUpdate. the relevant files as follows:
<target name="schemaupdate">
<taskdef name="schemaupdate"
classname="org.hibernate.tool.hbm2ddl.SchemaUpdateTask"
classpathref="hibernate.classpath"/>
<schemaupdate
properties="hibernate.properties"
quiet="no">
<fileset dir="">
<include name="model/*.hbm.xml"/>
</fileset>
</schemaupdate>
</target>
<?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 >
<class name="model.AccountView" >
<id name="enumItemId" type="int" column="ENUMITEMID" >
<generator class="native" />
</id>
<many-to-one name="user" class="com.jcalc.core.entity.UserAbs" column="USERID" not-null="true" insert="false" update="false" />
<property name="name" column="NAME" />
<property name="value" column="VALUE" type="serializable" />
</class>
</hibernate-mapping>
what else should I be looking for?
also, I have a log4j.properties file in the same dir as build.xml, but I get an error
[schemaupdate] log4j:WARN No appenders could be found for logger (org.hibernate.cfg.Environment).
[schemaupdate] log4j:WARN Please initialize the log4j system properly.
do I need to declare log4j else where?
|