Skip to Main Content

Oracle Database Discussions

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

ORA-01843: not a valid month

user565514Apr 11 2007 — edited Apr 11 2007
Dear all,

I have a problem with a date field...

I first execute the statements

SET DEFINE OFF;
alter session set NLS_DATE_FORMAT='yyyy-mm-dd hh24:mi:ss';

The I execute the statement

select * from nls_session_parameters where parameter = 'NLS_DATE_FORMAT';

and get

PARAMETER
--------------------------------------------------------------------------------
VALUE
--------------------------------------------------------------------------------
NLS_DATE_FORMAT
YYYY-MM-DD HH24:MI:SS

I finally execute the statement

INSERT INTO document (id, title, updateDate, archive, channel, documentNumber, revision, language, format, informationType, preparedBy, securityClass, sizeInBytes, category, createDate, deleteDate, test, accessClass, in1095, inDocNumber, inDocPlan, inFind, piiAddDate, accesses30days, documentUrl, accessesToTime) VALUES (30730,'Product Relationships & Product Structuring','2003-06-02 15:10:09','GASK2','Intranet','EDTMASV-03:008','A','EN','MSPOWERPOINT2000',NULL,'EDTMASV',NULL,151040,'other','2003-06-02 00:00:00',NULL,'0','W','0','0','0','','2006-10-08 11:26:43',7,NULL,NULL);

and get the following error

INSERT INTO document (id, title, updateDate, archive, channel, documentNumber, revision, language, format, informationType, preparedBy, securityClass, sizeInBytes, category, createDate, deleteDate, test, accessClass, in1095, inDocNumber, inDocPlan, inFind, piiAddDate, accesses30days, documentUrl, accessesToTime) VALUES (30730,'Product Relationships & Product Structuring','2003-06-02 15:10:09','GASK2','Intranet','EDTMASV-03:008','A','EN','MSPOWERPOINT2000',NULL,'EDTMASV',NULL,151040,'other','2003-06-02 00:00:00',NULL,'0','W','0','0','0','','2006-10-08 11:26:43',7,NULL,NULL)
*
ERROR at line 1:
ORA-01843: not a valid month

The table struture is

SQL> desc document;
Name Null? Type
----------------------------------------- -------- ----------------------------
ID NOT NULL NUMBER(19)
TITLE VARCHAR2(255 CHAR)
UPDATEDATE TIMESTAMP(6)
ARCHIVE VARCHAR2(255 CHAR)
CHANNEL VARCHAR2(255 CHAR)
DOCUMENTNUMBER VARCHAR2(255 CHAR)
REVISION VARCHAR2(255 CHAR)
LANGUAGE VARCHAR2(255 CHAR)
FORMAT VARCHAR2(255 CHAR)
INFORMATIONTYPE VARCHAR2(255 CHAR)
PREPAREDBY VARCHAR2(255 CHAR)
SECURITYCLASS VARCHAR2(255 CHAR)
SIZEINBYTES NUMBER(19)
CATEGORY VARCHAR2(255 CHAR)
CREATEDATE TIMESTAMP(6)
DELETEDATE TIMESTAMP(6)
TEST NUMBER(1)
ACCESSCLASS VARCHAR2(255 CHAR)
IN1095 NUMBER(1)
INDOCNUMBER NUMBER(1)
INDOCPLAN NUMBER(1)
INFIND NUMBER(1)
PIIADDDATE TIMESTAMP(6)
ACCESSES30DAYS NUMBER(10)
DOCUMENTURL VARCHAR2(255 CHAR)
ACCESSESTOTIME TIMESTAMP(6)
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on May 9 2007
Added on Apr 11 2007
15 comments
25,718 views