What is date format and how to check it?

>Hi,
>
>Am testing Oracle 8.05 enterprise edition on AIX 4.3.1
>The following query works fine on Oracle 7.3, but gives an
>error :ORA-01858 on Oracle 8.05
>

sounds like someone might have changed your default date mask, perhaps in the
init.ora.

what does:

  1* select * from v$nls_parameters where parameter = 'NLS_DATE_FORMAT'
[email protected]> /

PARAMETER
----------------------------------------------------------------
VALUE
----------------------------------------------------------------
NLS_DATE_FORMAT
dd-mon-yyyy
 

return?  if it doesn't return DD-MON-YY then someone has changed it.

>It cribs on the date field, saying a non-numeric character
>was found where a numeric was expected.
>----------------------------------------------------------------------------
>-----------------
>
>SQL> desc temp
> Name                            Null?    Type
> ------------------------------- -------- ----
> BR_CODE                         NOT NULL VARCHAR2(4)
> CCY_CODE                        NOT NULL VARCHAR2(4)
> DESCRIP                                  VARCHAR2(10)
> TEMP1_DT                                 DATE
>
>SQL> INSERT INTO TEMP VALUES(
> '1212',
> '2121',
> 'AAAAAA',
> '31-DEC-99');
>
>
>'31-DEC-99')
>*
>ERROR at line 1:
>ORA-01858: a non-numeric character was found where a numeric was expected
>----------------------------------------------------------------------------
>------------
>
>Auto conversion from char to date is not happening.
>This works fine when i use the TO_DATE function for
>testing.
>
>However, am not in a position to use the TO_DATE
>function, as the update to the database will be done by
>a third party tool, that relies on Oracle to auto-convert a
>date supplied in the DD-MON-YY format.
>
>Am  facing a similar problem on the SQL*Loader too.
>
>Any clues?...
>
>Thanks,
>VJ
>
>
>
>
 

--
See http://govt.us.oracle.com/~tkyte/ for my columns 'Digging-in to Oracle8i'...
Current article is "Part I of V, Autonomous Transactions" updated June 21'st

Thomas Kyte                   [email protected]
Oracle Service Industries     Reston, VA   USA

Opinions are mine and do not necessarily reflect those of Oracle Corporation

Hosted by www.Geocities.ws

1