Hi, I'm using JDK 1.4.0, Hibernate 2.0.1 and hibernate-extensions-2.0 Hbm2java.bat is below, I have modified it so that it includes setenv.bat.
****************************************************** @echo off rem ------------------------------------------------------------------- rem Execute hbm2java tool rem ------------------------------------------------------------------- set JDBC_DRIVER=d:\OracleWorkBench\jdbc\lib\classes12.jar;d:\OracleWorkBench\jdb c\lib\nls_charset12.jar; set HIBERNATE_HOME=d:\hibernate-2.0 set CORELIB=%HIBERNATE_HOME%\lib set LIB=..\lib set PROPS=%HIBERNATE_HOME%\src set CP=%JDBC_DRIVER%;%PROPS%;%HIBERNATE_HOME%\hibernate2.jar;%CORELIB%\commons-l ogging.jar;%CORELIB%\commons-collections.jar;%CORELIB%\commons-lang.jar;%COR ELIB%\cglib.jar;%CORELIB%\dom4j.jar;%CORELIB%\odmg.jar;%CORELIB%\xml-apis.ja r;%CORELIB%\xerces.jar;%CORELIB%\xalan.jar;%LIB%\jdom.jar;D:\hibernate-2.0\h ibernate-extensions-2.0\tools\hibernate-tools.jar;d:\jboss-3.2.1_tomcat-4.1. 24\client\concurrent.jar;d:\jboss-3.2.1_tomcat-4.1.24\client\jbossall-client .jar;d:\j2sdkee1.3.1\lib\j2ee.jar;d:\jboss-3.2.1_tomcat-4.1.24\jboss-common- client.jar;d:\jboss-3.2.1_tomcat-4.1.24\client\jnp-client.jar;d:\jboss-3.2.1 _tomcat-4.1.24\server\default\lib\jbossmq.jar;d:\jboss-3.2.1_tomcat-4.1.24\l ib;d:\jboss-3.2.1_tomcat-4.1.24\client;d:\jboss-3.2.1_tomcat-4.1.24\server\d efault\lib;d:\oracleworkbench\jdbc\lib;d:\jwsdp-1.1\bin;d:\jwsdp-1.1\lib;d:\ jwsdp-1.1\common\lib;d:\j2sdk1.4.0\bin;d:\j2sdk1.4.0\lib;d:\j2sdkee1.3.1\bin ;d:\j2sdkee1.3.1\lib;d:\jwsdp-1.1\common\lib;d:\jwsdp-1.1\saaj-1.1.1\lib;d:\ jwsdp-1.1\jaxm-1.1.1\lib;d:\junit3.8.1;d:\j2sdk1.4.0\jre\bin;d:\j2sdk1.4.0\j re\lib;. java -cp %CP% net.sf.hibernate.tool.hbm2java.CodeGenerator %* ****************************************************** Maybe there's something wrong with my classpath, is there? Best Regards. -----Original Message----- From: [EMAIL PROTECTED] [mailto:[EMAIL PROTECTED] Sent: Friday, August 01, 2003 04:48 To: Serkan Soykan Cc: [EMAIL PROTECTED]; [EMAIL PROTECTED] Subject: Re: [Hibernate] hbm2java newbie problem What JDK is it? this is a very weird problem that people sometimes observe .... I think we manged to trace it down to a JVM bug. If you are able to help me reproduce this in my environment, I'd really appreciate it. |---------+-------------------------------------------> | | "Serkan Soykan" | | | <[EMAIL PROTECTED]> | | | Sent by: | | | [EMAIL PROTECTED]| | | ceforge.net | | | | | | | | | 01/08/03 12:53 AM | | | | |---------+-------------------------------------------> >--------------------------------------------------------------------------- ---------------------------------------------------| | | | To: <[EMAIL PROTECTED]> | | cc: | | Subject: [Hibernate] hbm2java newbie problem | >--------------------------------------------------------------------------- ---------------------------------------------------| Hi, I'm trying to generate Java source files from a hibernate mapping file using hbm2java and I get the following error: Mapping file: ------------- <?xml version="1.0"?> <!DOCTYPE hibernate-mapping PUBLIC "-//Hibernate/Hibernate Mapping DTD 2.0//EN" "http://hibernate.sourceforge.net/hibernate-mapping-2.0.dtd"> <hibernate-mapping> <class name="kkdb.hnate.Card" table="cards"> <id name="serNo" column="serno" type="long"> <generator class="native"/> </id> <property name="number_" column="Number_" type="string"/> <property name="currency" column="Currency" type="string"/> <property name="stGeneral" column="StGeneral" type="string"/> <property name="firstName" column="FirstName" type="string"/> <property name="lastName" column="LastName" type="string"/> <property name="product" column="Product" type="string"/> </class> </hibernate-mapping> Error: --------- Java net.sf.hibernate.tool.hbm2java.CodeGenerator Card.hbm.xml Exception in thread "main" java.lang.ExceptionInInitializerError: java.lang.NullPointerException at java.util.HashMap.put(Unknown Source) at net.sf.hibernate.type.TypeFactory.<clinit>(TypeFactory.java:50) at net.sf.hibernate.tool.hbm2java.ClassMapping.getFieldType(ClassMapping.java:6 15) at net.sf.hibernate.tool.hbm2java.ClassMapping.initWith(ClassMapping.java:195) at net.sf.hibernate.tool.hbm2java.ClassMapping.<init>(ClassMapping.java:73) at net.sf.hibernate.tool.hbm2java.CodeGenerator.main(CodeGenerator.java:99) Any ideas? Best regards... Ismail Serkan SOYKAN Information Technologies Kocbank A.S. Phone: +90(216)4540600-4612 E-mail: [EMAIL PROTECTED] Bu mesaj ve onunla iletilen tüm ekler gönderildigi kisi ya da kuruma özel ve Bankalar Kanunu geregince, gizlilik yükümlülügü tasiyor olabilir. Bu mesaj, hiçbir sekilde, herhangi bir amaç için çogaltilamaz, yayinlanamaz ve para karsiligi satilamaz; mesajin yetkili alicisi veya alicisina iletmekten sorumlu kisi degilseniz, mesaj içerigini ya da eklerini kopyalamayiniz, yayinlamayiniz, baska kisilere yönlendirmeyiniz ve mesaji gönderen kisiyi derhal uyararak bu mesaji siliniz. Bu mesajin içeriginde ya da eklerinde yer alan bilgilerin dogrulugu, bütünlügü ve güncelligi Bankamiz tarafindan garanti edilmemektedir ve bilinen virüslere karsi kontrolleri yapilmis olarak yollanan mesajin sisteminizde yaratabilecegi zararlardan Bankamiz sorumlu tutulamaz. This message and the files attached to it are under the privacy liability in accordance with the Banking Law and confidential to the use of the individual or entity to whom they are addressed.This message cannot be copied, disclosed for any purpose or sold for any monetary consideration. If you are not the intended recipient of this message, you should not copy, distribute, disclose or forward the information that exists in the content and in the attachments of this message; please notify the sender immediately and delete all copies of this message. Our Bank does not warrant the accuracy, integrity and currency of the information transmitted with this message. This message has been detected for all known computer viruses hence our Bank is not liable for the occurrence of any system corruption caused by this message. ********************************************************************** Any personal or sensitive information contained in this email and attachments must be handled in accordance with the Victorian Information Privacy Act 2000, the Health Records Act 2001 or the Privacy Act 1988 (Commonwealth), as applicable. This email, including all attachments, is confidential. If you are not the intended recipient, you must not disclose, distribute, copy or use the information contained in this email or attachments. Any confidentiality or privilege is not waived or lost because this email has been sent to you in error. If you have received it in error, please let us know by reply email, delete it from your system and destroy any copies. ********************************************************************** ------------------------------------------------------- This SF.Net email sponsored by: Free pre-built ASP.NET sites including Data Reports, E-commerce, Portals, and Forums are available now. Download today and enter to win an XBOX or Visual Studio .NET. http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet_072303_01/01 _______________________________________________ hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel Bu mesaj ve onunla iletilen tüm ekler gönderildigi kisi ya da kuruma özel ve Bankalar Kanunu geregince, gizlilik yükümlülügü tasiyor olabilir. Bu mesaj, hiçbir sekilde, herhangi bir amaç için çogaltilamaz, yayinlanamaz ve para karsiligi satilamaz; mesajin yetkili alicisi veya alicisina iletmekten sorumlu kisi degilseniz, mesaj içerigini ya da eklerini kopyalamayiniz, yayinlamayiniz, baska kisilere yönlendirmeyiniz ve mesaji gönderen kisiyi derhal uyararak bu mesaji siliniz. Bu mesajin içeriginde ya da eklerinde yer alan bilgilerin dogrulugu, bütünlügü ve güncelligi Bankamiz tarafindan garanti edilmemektedir ve bilinen virüslere karsi kontrolleri yapilmis olarak yollanan mesajin sisteminizde yaratabilecegi zararlardan Bankamiz sorumlu tutulamaz. This message and the files attached to it are under the privacy liability in accordance with the Banking Law and confidential to the use of the individual or entity to whom they are addressed. This message cannot be copied, disclosed or sold monetary consideration for any purpose. If you are not the intended recipient of this message, you should not copy, distribute, disclose or forward the information that exists in the content and in the attachments of this message; please notify the sender immediately and delete all copies of this message. Our Bank does not warrant the accuracy, integrity and currency of the information transmitted with this message. This message has been detected for all known computer viruses thence our Bank is not liable for the occurrence of any system corruption caused by this message. ------------------------------------------------------- This SF.Net email sponsored by: Free pre-built ASP.NET sites including Data Reports, E-commerce, Portals, and Forums are available now. Download today and enter to win an XBOX or Visual Studio .NET. http://aspnet.click-url.com/go/psa00100003ave/direct;at.aspnet_072303_01/01 _______________________________________________ hibernate-devel mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/hibernate-devel