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

Re: Date format



Charu

What version of SQR are you using ? If on 4.x you may need to set in
your sqr.ini

[Environment:Common]
SQR_DB_DATE_FORMAT=dd/mm/yyyy  ( or whatever format you chose )

see chapter 8 p325 of the 4 manual

Mark Pietersz


> -----Original Message-----
> From: Charu Srinivas [SMTP:C._Srinivas/dsisys/US@DSISYS.COM]
> Sent: Thursday, September 03, 1998 5:07 AM
> To:   Multiple recipients of list SQR-USERS
> Subject:
>
> Platform - Windows NT
> Database - Oracle
>
> Problem -
>
>  I am using PeopleSoft SQR for the payroll process. This SQR compares
> the
> prompted for date with the date extracted from the database. The input
> date
> is in mm/dd/yy (input : 08/30/98) format and is converted to the
> dd-mon-yyyy
> (result: 30-AUG-1998) format using the Format-Datetime routine as
> follows:
>               Format-Datetime($Pay_End_Dt,$Pay_End_Dt,
> {Prompt-Mask},'','
> native') where
>              {Prompt-Mask} is 'mdy' and the native date format is
> DD-MON-YYYY and .
>
> The date that is retrieved from the database is in the format
> DD-MON-YY
> (30-AUG-98). So when the two dates are compared, they are found to be
> unequal because one has a two-digit year and the other has a
> four-digit
> year.
>
> I tried to use the to_date(  Pay_End_dt, 'DD-MON-YYYY') to convert the
> date
> from the database to four-digit year format.
> And I also changed the value of $Year4 variable in the setenv.sqc to
> 1. But
> I still get the same two-digit year from the database.
>
> Thanks!!
> Charu