File APIs for Java Developers
Manipulate DOC, XLS, PPT, PDF and many others from your application.
http://aspose.com/file-tools
The moose likes JDBC and the fly likes I have a doubt in oracle! Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login
JavaRanch » Java Forums » Databases » JDBC
Bookmark "I have a doubt in oracle!" Watch "I have a doubt in oracle!" New topic
Author

I have a doubt in oracle!

Arun Soundar
Greenhorn

Joined: Jan 17, 2005
Posts: 1
I want to get the data from the database such that I would get the data between 2 dates inclusive of the given dates. Using Between function returns only the data between the 2 dates without including the from date.
Paul Sturrock
Bartender

Joined: Apr 14, 2004
Posts: 10336

I think you've misunderstood the Oracle documentation; you can understand "between" to mean "greater than or equal to the first value, and less than or equal to the second". So:

means that the value of <param> is any value in the set {1, 2, 3, 4, 5, 6, 7, 8, 9, 10}.

An result of this is that the between comparison operator implicitly requires ordering. If I wrote it the other way:

This would only return true if the value of <param> was not in the set {2, 3, 4, 5, 6, 7, 8, 9}.

[ January 17, 2005: Message edited by: Paul Sturrock ]
[ January 17, 2005: Message edited by: Paul Sturrock ]

JavaRanch FAQ HowToAskQuestionsOnJavaRanch
 
I agree. Here's the link: http://aspose.com/file-tools
 
subject: I have a doubt in oracle!
 
Similar Threads
Dates
Simple logic for getting the no.of "Day" s between 2 dates
No.of SUNDAY's between two dates???
Date Difference
How to get the difference between 2 dates ?