How can i persist date and Time with JPA Hibernate in MySql database ? -


i want persist date , time jpa in mysql database.

but problem is, date correct, not time. time 02:00:00

my implementation in entity class following:

@temporal(temporaltype.timestamp) private date date; 

and how set im action class date:

actualfactory.setdate(new java.util.date()); 

the result in db date colum today :

2015-09-30 02:00:00 


Comments

Popular posts from this blog

html - Outlook 2010 Anchor (url/address/link) -

javascript - Why does running this loop 9 times take 100x longer than running it 8 times? -

Getting gateway time-out Rails app with Nginx + Puma running on Digital Ocean -