[Date Prev][Date Next][Thread Prev][Thread Next]
[Author Index] [Date Index] [Thread Index]
[SQR-USERS Info] [SQRUG Home Page]

Re: Date Comparison in Oracle



Get the Date into a format that is comparable for your purposes, i.e.
julian or 'YYYYMMDD'. Needless to say the dates should also be in the
same format.

Since you are using Oracle, TO_CHAR() may be used in your SQR Select
to convert date values into your desired format. If datetime.sqc is
delivered in standard SQR, (it is in PeopleSoft), you could
investigate conversion routines there.

HTH

Steve

---"Hope, Sandra" <HopeS@DYNCORP.COM> wrote:
>
> I need to select the earlier of several dates within an SQR.
> I've tried various date formats and using
>
>   if $Date1 < Date2
>         let $Date3 = Date2
>   end-if
>
> I don't get date errors but the program simply replaces each date
whether it
> is earlier or not.  Is there a special format required for this
syntax or is
> there a different way to compare dates?   Thanks All.
>
> SHope
>

==


Steven E. Davies
------------------------------
"Quid quid latine dictum sit,
 altum viditur."
------------------------------
_________________________________________________________
DO YOU YAHOO!?
Get your free @yahoo.com address at http://mail.yahoo.com