-->
These old forums are deprecated now and set to read-only. We are waiting for you on our new forums!
More modern, Discourse-based and with GitHub/Google/Twitter authentication built-in.

All times are UTC - 5 hours [ DST ]



Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 
Author Message
 Post subject: select sysdate from dual
PostPosted: Wed Jun 22, 2005 5:55 pm 
Newbie

Joined: Wed Jun 22, 2005 5:52 pm
Posts: 2
I would like to do a simple query with hibernate where I grab the sysdate from the database. I get an invalid table name error. Is there a way to do this?


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jun 22, 2005 11:01 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 7:19 pm
Posts: 2364
Location: Brisbane, Australia
Native SQL query, or dummy mapping for Dual, or JDBC (get connection from the Session, or use an existing mapped table reference.


Top
 Profile  
 
 Post subject:
PostPosted: Wed Jun 22, 2005 11:03 pm 
Hibernate Team
Hibernate Team

Joined: Tue Aug 26, 2003 7:19 pm
Posts: 2364
Location: Brisbane, Australia
If your running the DB on the same machine as the appplication then you could just use 'new Date();'.


Top
 Profile  
 
Display posts from previous:  Sort by  
Forum locked This topic is locked, you cannot edit posts or make further replies.  [ 3 posts ] 

All times are UTC - 5 hours [ DST ]


You cannot post new topics in this forum
You cannot reply to topics in this forum
You cannot edit your posts in this forum
You cannot delete your posts in this forum

Search for:
© Copyright 2014, Red Hat Inc. All rights reserved. JBoss and Hibernate are registered trademarks and servicemarks of Red Hat, Inc.