Oracle FAQ | Your Portal to the Oracle Knowledge Grid |
Home -> Community -> Usenet -> c.d.o.server -> nls_date_format & Y2K
When I put this in initsid.ora:
NLS_DATE_FORMAT = DD-MON-RR Oracle's sys table looks OK:
select name,value from v$parameter where name = 'nls_date_format'; nls_date_format DD-MON-RR
But, a sqlplus session ignores the nls_date_format:
SQL> select to_char( to_date('10-JAN-00'), 'DD-MON-YYYY' ) from dual;
10-JAN-1900 And I discover that sqlplus uses the DD-MON-RR format when either:
(a) I put it in the unix env ( setenv NLS_DATE_FORMAT DD-MON-RR ),
or
(b) I issue [ALTER SESSION SET NLS_DATE_FORMAT='DD-MON-RR'] in
sqlplus
For either of these:
SQL> select to_char( to_date('10-JAN-00'), 'DD-MON-YYYY' ) from dual;
10-JAN-2000 In addition, if I take NLS_DATE_FORMAT out of initsid.ora, then (a) & (b) above will still work;
To me, Y2K Compliance means _always_ using the DD-MON-RR format, and I can't guarantee that all clients will have (a)/(b).
To be Y2K, I need to have the initsid.ora setting be the default for all clients.
So, can anyone get DD-MON-RR as the default using only the initsid.ora setting?
I'm using 7.3.2.3 and sun/solaris2.5
Cheers,
Steve
Received on Sat Jun 27 1998 - 05:11:45 CDT