This week's giveaway is in the EJB and other Java EE Technologies forum.
We're giving away four copies of EJB 3 in Action and have Debu Panda, Reza Rahman, Ryan Cuprak, and Michael Remijan on-line!
See this thread for details.
The moose likes JDBC and the fly likes Hi, if the field of the table in mySQL is of type TimeStamp, how would I get it by ResultSet? Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of EJB 3 in Action this week in the EJB and other Java EE Technologies forum!
JavaRanch » Java Forums » Databases » JDBC
Bookmark "Hi, if the field of the table in mySQL is of type TimeStamp, how would I get it by ResultSet?" Watch "Hi, if the field of the table in mySQL is of type TimeStamp, how would I get it by ResultSet?" New topic
Author

Hi, if the field of the table in mySQL is of type TimeStamp, how would I get it by ResultSet?

Jacky Luk
Ranch Hand

Joined: Aug 02, 2012
Posts: 580


This doesn't work, it creates a stack dump.
BTW, is there a third part tool that maps the database into table easily?
Thanks
Jack
nir sharma
Ranch Hand

Joined: Sep 11, 2012
Posts: 72

Jack Luk wrote:
This doesn't work, it creates a stack dump.


try


BTW, is there a third part tool that maps the database into table easily?

What exactly are you trying to do?
Kemal Sokolovic
Bartender

Joined: Jun 19, 2010
Posts: 825
    
    5

Use getTimestamp(int colIndex) that returns Timestamp.


The quieter you are, the more you are able to hear.
Jacky Luk
Ranch Hand

Joined: Aug 02, 2012
Posts: 580
Kemal Sokolovic wrote:Use getTimestamp(int colIndex) that returns Timestamp.


Thank you so much!
Martin Vajsar
Sheriff

Joined: Aug 22, 2010
Posts: 3429
    
  47

Moved to our JDBC forum.


Jack Luk wrote:BTW, is there a third part tool that maps the database into table easily?

Lots of them. Try to search for persistence framework or object-relational maping. We have a separate forum (Object Relational Mapping) dedicated to it.
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Hi, if the field of the table in mySQL is of type TimeStamp, how would I get it by ResultSet?
 
Similar Threads
Problem with JTable when no. of records are more than the size of frame!!!
SQLException:Invalid column name
Problem with table row overlapping with table header
WA #1.....word association
Table distortion on form submission