db2 « Insert « JPA Q&A





1. How do I resolve an "Illegal Conversion" exception when inserting to an XML column?    stackoverflow.com

I have a table with a column of type XML. When I insert a record into this table from a servlet running in WebSphere on Windows, the insert succeeds. ...

2. insert problem in db2    forum.hibernate.org

3. Unable to insert row into a DB2 table with identity column    forum.hibernate.org

Somebody please help me. I am trying to insert a row to a Db2 table which has an identity column and having problems. I have the details below. The ID type in my java code is "int" and the identity column data type in DB2 table is also of type integer. b]Hibernate version:[/b] 2.1 Mapping documents: ...

4. HIbernate with DB2 database - problem with insert / update    forum.hibernate.org

Newbie Joined: Thu Jan 26, 2006 1:54 am Posts: 4 My environment is as follows: Java 1.4.x, Hibernate 2, DB2 Database. Table definition: CREATE TABLE service_category ( id BIGINT NOT NULL GENERATED BY DEFAULT AS IDENTITY, name VARCHAR(255) default NULL, description BLOB(65K), parent_id BIGINT default 1, update_date TIMESTAMP NOT NULL, create_date TIMESTAMP NOT NULL default CURRENT TIMESTAMP, update_user VARCHAR(32) default 'admin', ...

5. Updation and Insertion Problem with DB2/400    forum.hibernate.org

Newbie Joined: Fri Apr 14, 2006 11:03 am Posts: 6 Hi, My Hibernate Config file. Code: org.hibernate.dialect.DB2400Dialect true false com.ibm.as400.access.AS400JDBCDriver jdbc:as400://172.18.0.14 ...

6. could not insert exception with db2    forum.hibernate.org

Hi, I get the following exception while trying to save my new instance. It works fine with MySql, but not with Db2. Any ideas? many thanks! ERROR - DB2 SQL error: SQLCODE: -302, SQLSTATE: 22001, SQLERRMC: null ERROR - Could not synchronize database state with session org.hibernate.exception.GenericJDBCException: could not insert: [eserve.bco_ta_address] at org.hibernate.exception.SQLStateConverter.handledNonSpecificException(SQLStateConverter.java:82) at org.hibernate.exception.SQLStateConverter.convert(SQLStateConverter.java:70) at org.hibernate.exception.JDBCExceptionHelper.convert(JDBCExceptionHelper.java:43) at org.hibernate.persister.entity.BasicEntityPersister.insert(BasicEntityPersister.java:1869) at org.hibernate.persister.entity.BasicEntityPersister.insert(BasicEntityPersister.java:2200) ...

7. Unable to Insert - DB2 Identity Column Error    forum.hibernate.org

Hi guys, I am having a strange problem while inserting into db2 table. Hibernate is generating sql with "default" in it and DB2 does not like it. What am I doing worng ? Thanks. Rahul. ----------------------------------------------------------- Hibernate version: 3.1.3 Mapping: