[Opensource] Type Mapping SQL Server 2000.

Dave davsmith at nbnet.nb.ca
Sun Jun 9 05:57:05 PDT 2002


Whoops, please disregard that last message.  It was MY error, I didn't 
drop ALL the tables before recreating them, therefore EVENTMAIL was 
subsequently recreated properly without ExpUid being set as an Identity 
column.

Just to confirm, the type mappings you provided DID work properly.  
Many thanks,
Dave

Dave Smith wrote:

> Thanks Michael ,
> I inserted the type mappings you provided into my default config and 
> it worked perfectly, ... almost.  Just two little hang-ups reported in 
> populating the default data to the EVENETMAIL table. 
> com.jcorporate.expresso.core.db.DBException: Unable to execute 
> statement: INSERT INTO EVENTMAIL (Event, Success, ExpUid) VALUES 
> ('SYSERROR', 'Y', 3)(com.jcorporate.expresso.services.dbobj.EventMail, 
> db/context 'default'):[Microsoft][SQLServer 2000 Driver for 
> JDBC][SQLServer]Cannot insert explicit value for identity column in 
> table 'EVENTMAIL' when IDENTITY_INSERT is set to OFF.
>    at 
> com.jcorporate.expresso.core.db.DBConnection.executeUpdate(DBConnection.java:597) 
>
>    at com.jcorporate.expresso.core.dbobj.DBObject.add(DBObject.java:351)
>    at 
> com.jcorporate.expresso.core.dbobj.SecuredDBObject.add(SecuredDBObject.java:248) 
>
>    at 
> com.jcorporate.expresso.services.dbobj.EventMail.populateDefaultValues(EventMail.java:173) 
>
>    at 
> com.jcorporate.expresso.core.dbobj.Schema.setupDefaultValuesWithException(Schema.java:848) 
>
>    at 
> com.jcorporate.expresso.core.utility.DBTool.populateTables(DBTool.java:2012) 
>
>
> com.jcorporate.expresso.core.db.DBException: Unable to add record to 
> database for record with key 'SYSERROR/3/Y' in database 
> 'default':Unable to execute statement: INSERT INTO EVENTMAIL (Event, 
> Success, ExpUid) VALUES ('SYSERROR', 'Y', 
> 3)(com.jcorporate.expresso.services.dbobj.EventMail, db/context 
> 'default'):[Microsoft][SQLServer 2000 Driver for 
> JDBC][SQLServer]Cannot insert explicit value for identity column in 
> table 'EVENTMAIL' when IDENTITY_INSERT is set to OFF. (INSERT INTO 
> EVENTMAIL (Event, Success, ExpUid) VALUES ('SYSERROR', 'Y', 
> 3)):[Microsoft][SQLServer 2000 Driver for JDBC][SQLServer]Cannot 
> insert explicit value for identity column in table 'EVENTMAIL' when 
> IDENTITY_INSERT is set to OFF.
>    at com.jcorporate.expresso.core.dbobj.DBObject.add(DBObject.java:354)
>    at 
> com.jcorporate.expresso.core.dbobj.SecuredDBObject.add(SecuredDBObject.java:248) 
>
>    at 
> com.jcorporate.expresso.services.dbobj.EventMail.populateDefaultValues(EventMail.java:173) 
>
>    at 
> com.jcorporate.expresso.core.dbobj.Schema.setupDefaultValuesWithException(Schema.java:848) 
>
>    at 
> com.jcorporate.expresso.core.utility.DBTool.populateTables(DBTool.java:2012) 
>
>
> Not sure why expresso sets up the ExpUid field  in the EVENTMAIL table 
> as an IDENTITY column. I'll do a little more digging.
> Many Thanks for the Type-Mappings.
>
> Dave
>





More information about the Opensource mailing list