With JBoss 3.0.1, CMP 2.0 and oracle.jdbc.driver.OracleDriver (Oracle DB
8.1.7) we try to map Timestamp-attributes to Oracle Date. We have no
problems with Timestamp and the Borland server.
The error message is as follows:
15:00:08,254 ERROR [Pant] Could not create entity
java.sql.SQLException: ORA-01841: (full) year must be between -4713 and +9999, and not
be 0
at oracle.jdbc.dbaccess.DBError.throwSqlException(DBError.java:168)
at oracle.jdbc.ttc7.TTIoer.processError(TTIoer.java:208)
at oracle.jdbc.ttc7.Oall7.receive(Oall7.java:543)
at oracle.jdbc.ttc7.TTC7Protocol.doOall7(TTC7Protocol.java:1405)
at oracle.jdbc.ttc7.TTC7Protocol.parseExecuteFetch(TTC7Protocol.java:822)
at
oracle.jdbc.driver.OracleStatement.executeNonQuery(OracleStatement.java:1446)
Using the p6spy-driver we can identify the insert statement as
follows (Why doesn't the JBoss log system provide the same amount of information?):
INSERT INTO PANT (pantId, tilstand, kontrollStatus, isin, foretaksNr, lopeNr, antall,
beholdning, beholdningsendring, uttrekningsBeholdning, uttrekningsDato, vpKontoNr,
vpKontoNrTil, erDelPant, prioritet, foretakTilstand, sikkerhet, endretAv, endret,
verifisertAv, verifisert, merknad) VALUES ('100000000000039', '0', '13',
'En-isin-kode', '971171324', 'Et-lopenr', '999.1234', '1000000', '', '', '2002-08-31
15:00:05.976', 'En-vpkonto', 'Enda-en-vpkonto', 'false', 'en-prioritet', '1', '13',
'nbjhh1', '2002-08-31 15:00:05.976', 'nbjhh1', '2002-08-31 15:00:05.976', 'En dummy
pant for testhensikt')
Running this query manually, I get a different error message (that
looks OK):
ERROR at line 1:
ORA-01830: date format picture ends before converting entire input string
(Because the stupid Oracle system does not like to get date strings in
any other format than is defined in the initora8.ora file: nls_date_format =
"YYYY-MM-DD")
PANT is defined as follows:
SQL> desc pant
Name Null? Type
----------------------------------------- -------- ----------------------------
PANTID NOT NULL NUMBER(19)
FORETAKSNR NOT NULL VARCHAR2(255)
LOPENR NOT NULL VARCHAR2(255)
ANTALL NOT NULL NUMBER(38,15)
TILSTAND NOT NULL NUMBER(19)
KONTROLLSTATUS NUMBER(19)
ISIN VARCHAR2(255)
BEHOLDNING NOT NULL NUMBER(19)
BEHOLDNINGSENDRING NUMBER(19)
UTTREKNINGSBEHOLDNING NUMBER(19)
UTTREKNINGSDATO DATE
VPKONTONR VARCHAR2(255)
VPKONTONRTIL VARCHAR2(255)
ERDELPANT NOT NULL NUMBER(1)
PRIORITET VARCHAR2(255)
FORETAKTILSTAND NOT NULL NUMBER(10)
SIKKERHET NOT NULL NUMBER(19)
ENDRETAV VARCHAR2(255)
ENDRET DATE
VERIFISERTAV VARCHAR2(255)
VERIFISERT DATE
MERKNAD DATE
-------------------------------------------------------
This sf.net email is sponsored by: OSDN - Tired of that same old
cell phone? Get a new here for FREE!
https://www.inphonic.com/r.asp?r=sourceforge1&refcode1=vs3390
_______________________________________________
JBoss-user mailing list
[EMAIL PROTECTED]
https://lists.sourceforge.net/lists/listinfo/jboss-user