![]() |
| ||
| Create hibernate.cfg.xml while program is running how to connet to database using hibernate, because i create hibernate.cfg.xml while is running i have build simple application for test connection to database using hibernate. when write application i'm not write hibernate.cfg.xml, but i want create while running. so when i click button show error like this [code] " "Jun 9, 2008 8:59:19 AM org.hibernate.cfg.Environment <clinit> INFO: Hibernate 3.2.1 Jun 9, 2008 8:59:19 AM org.hibernate.cfg.Environment <clinit> INFO: hibernate.properties not found Jun 9, 2008 8:59:19 AM org.hibernate.cfg.Environment buildBytecodeProvider INFO: Bytecode provider name : cglib Jun 9, 2008 8:59:19 AM org.hibernate.cfg.Environment <clinit> INFO: using JDK 1.4 java.sql.Timestamp handling Jun 9, 2008 8:59:19 AM org.hibernate.cfg.Configuration configure INFO: configuring from resource: /hibernate.cfg.xml Jun 9, 2008 8:59:19 AM org.hibernate.cfg.Configuration getConfigurationInputStream INFO: Configuration resource: /hibernate.cfg.xml error connected /hibernate.cfg.xml not found " [\code] this my code private void jButton1ActionPerformed(java.awt.event.ActionEvent evt) {this file hibernate.cfg.xml i create while running <?xml version='1.0' encoding='utf-8'?> because i want make connection more flexible using hibernate, who user can connect to other database or server. thx |
| All times are GMT -4. The time now is 2:13 am. |
Forum system based on vBulletin Copyright ©2000 - 2009, Jelsoft Enterprises Ltd.
©2003 - 2009 DaniWeb® LLC