Search...
FAQs
Subscribe
Pie
FAQs
Recent topics
Flagged topics
Hot topics
Best topics
Search...
Search within Beginning Java
Search Coderanch
Advance search
Google search
Register / Login
Post Reply
Bookmark Topic
Watch Topic
New Topic
programming forums
Java
Mobile
Certification
Databases
Caching
Books
Engineering
Micro Controllers
OS
Languages
Paradigms
IDEs
Build Tools
Frameworks
Application Servers
Open Source
This Site
Careers
Other
Pie Elite
all forums
this forum made possible by our volunteer staff, including ...
Marshals:
Campbell Ritchie
Jeanne Boyarsky
Ron McLeod
Paul Clapham
Liutauras Vilda
Sheriffs:
paul wheaton
Rob Spoor
Devaka Cooray
Saloon Keepers:
Stephan van Hulst
Tim Holloway
Carey Brown
Frits Walraven
Tim Moores
Bartenders:
Mikalai Zaikin
Forum:
Beginning Java
Converting Date between Java and DB
Morley Yeung
Greenhorn
Posts: 8
posted 22 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
How can I convert the Date between
Java
's Date class and the DB's Date datatype?
Manfred Leonhardt
Ranch Hand
Posts: 1492
posted 22 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
Hi Morley,
You can just do the following:
java.util.Date d1 = new java.util.Date(); java.sql.Date d2 = new java.sql.Date( d1.getTime() );
Regards,
Manfred.
Morley Yeung
Greenhorn
Posts: 8
posted 22 years ago
Number of slices to send:
Optional 'thank-you' note:
Send
Thank you very much.
Consider Paul's
rocket mass heater
.
reply
reply
Bookmark Topic
Watch Topic
New Topic
Boost this thread!
Similar Threads
how to get duration starting date to ending date in visual jsf
Between Syntax
date difference
Date difference
comparing dates in db2
More...