•
•
•
•
What is DaniWeb IT Discussion Community?
You're currently browsing the Java section within the Software Development category of DaniWeb, a massive community of 361,873 software developers, web developers, Internet marketers, and tech gurus who are all enthusiastic about making contacts, networking, and learning from each other. In fact, there are 2,391 IT professionals currently interacting right now! Registration is free, only takes a minute and lets you enjoy all of the interactive features of the site.
Please support our Java advertiser: Lunarpages Java Web Hosting
Views: 2944 | Replies: 2
![]() |
•
•
Join Date: Mar 2007
Location: Islamabad, Pakistan
Posts: 19
Reputation:
Rep Power: 2
Solved Threads: 1
Use PreparedStatement and new Date (using java.sql.Date not java.util.Date).
If you question is how to formulate a query in general, then please find an SQL forum.
If you question is how to formulate a query in general, then please find an SQL forum.
Java Programmer and Sun Systems Administrator
----------------------------------------------
Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it.
--Brian Kernighan
----------------------------------------------
Debugging is twice as hard as writing the code in the first place. Therefore, if you write the code as cleverly as possible, you are, by definition, not smart enough to debug it.
--Brian Kernighan
•
•
Join Date: Jul 2006
Location: Dublin,California
Posts: 2
Reputation:
Rep Power: 0
Solved Threads: 0
If you have a query to fire , then use the SYSDATE as the standard one.
For example, on Oracle if I query as follows,
"select SYSDATE from DUAL", it should get me today's date. You may need to use this as part of your query. I understand you are in the midst of a Java program
So, after your query is built at Java area, you need to use the word "SYSDATE" which Oracle understands. I think it can work on other Databases too. But you may check it once.
Hope this helped.
For example, on Oracle if I query as follows,
"select SYSDATE from DUAL", it should get me today's date. You may need to use this as part of your query. I understand you are in the midst of a Java program
So, after your query is built at Java area, you need to use the word "SYSDATE" which Oracle understands. I think it can work on other Databases too. But you may check it once.
Hope this helped.
![]() |
•
•
•
•
Currently Active Users Viewing This Thread: 1 (0 members and 1 guests)
•
•
•
•
•
•
•
•
DaniWeb Java Marketplace
- i want to use reply a mail giving senders sending date as reference. (PHP)
- Help needed with Dates and Access (ASP)
- Date and Time (ASP.NET)
- trying to do a date of birth comparison. (Java)
- Microsoft Access date validation (Computer Science and Software Design)
- gwt the record which match the current date (Visual Basic 4 / 5 / 6)
Other Threads in the Java Forum
- Previous Thread: JTextField to only accept numbers
- Next Thread: Java Simple calc



Linear Mode