File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes Java in General and the fly likes Date checking Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Soft Skills this week in the Jobs Discussion forum!
JavaRanch » Java Forums » Java » Java in General
Bookmark "Date checking" Watch "Date checking" New topic
Author

Date checking

MInu
Ranch Hand

Joined: Oct 09, 2003
Posts: 517
Hi all,

I have some issues please help me to solve these.I will get the 'from date' and 'to date' from the JSP page. I will get some dates from the datbase also .I have to find the dates that will come under the start date and end date from the JSP.

Please help me....


God Gave Me Nothing I Wanted<br />He Gave Me Everything I Needed<br /> - Swami Vivekananda
pascal betz
Ranch Hand

Joined: Jun 19, 2001
Posts: 547
this is vague... how do you get the dates form the database ? what do you mean by "under the start date".

do you read the from/to from a form (well, from the form you get Strings, you need DateFormat to parse them to Date objects) ? then you need to find some records in the database that are in the range of these two dates ?

if yes, then restrict your DB query by the dates you get form the form. use a PreparedStatement and the setDate() methods for this.
if no, then perhaps someone else understood and can jump in. otherwise you need to give some more explanation, code, ...

pascal
Bear Bibeault
Author and ninkuma
Marshal

Joined: Jan 10, 2002
Posts: 61760
    
  67

It's not clear what your question is, but it's certainly not appropriate for this forum.

Moved to Java in General (intermediate).


[Asking smart questions] [Bear's FrontMan] [About Bear] [Books by Bear]
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: Date checking