aspose file tools*
The moose likes JDBC and the fly likes illegalArgumentException, HSQLDB, and Hibernate Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "illegalArgumentException, HSQLDB, and Hibernate" Watch "illegalArgumentException, HSQLDB, and Hibernate" New topic
Author

illegalArgumentException, HSQLDB, and Hibernate

Stuart Rogers
Ranch Hand

Joined: Oct 02, 2008
Posts: 139
Greetings,

So I whipped up a java/swing/hibernate/hsqldb desktop app in Eclipse.

pertinent.cfg.xml


...seems ok as code runs through my HibernateUtil.java fine.
My StudentOfDistrict class has a constructor that takes an array of Strings.


Since I'm just in the prototyping stage right now I manually start the HSQLDB server from within a CommandWindow before attempting to execute the app from within Eclipse.
as
M$prompt> java -classpath hsqldb.jar org.hsqldb.Server

this does bring up the server

then executing the app connection to server is made, all goes well until I actually try to create a new instance of StudentOfDistrict ( insert a row into students_of_district)

but

fails with a illegalArgumentException

I know the database server is up and a connection is made, but I don't know if the table students_of_district is getting automatically created by Hibernate prior to trying to insert.

Any ideas?

TIA,

Still-learning Steve
David O'Meara
Rancher

Joined: Mar 06, 2001
Posts: 13459

what is the stack trace?
Stuart Rogers
Ranch Hand

Joined: Oct 02, 2008
Posts: 139
My bad... the offending snippet had nothing to do with HSQLDB or Hibernate... I had the wrong date-formatting within my constructor



where in my EDA_utils.java


DoH!

But, thanks for looking on a Saturday night! Now it's Miller Time!

CASE CLOSED


Still-learning Steve
David O'Meara
Rancher

Joined: Mar 06, 2001
Posts: 13459

Thanks for dropping an update, it helps.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: illegalArgumentException, HSQLDB, and Hibernate