Insert Errors using Triggers to load Identity

Discussion of open issues, suggestions and bugs regarding ADO.NET provider for Oracle
Post Reply
Posts: 3
Joined: Fri 26 Sep 2008 20:50

Insert Errors using Triggers to load Identity

Post by jkuhn » Fri 10 Oct 2008 21:22

Our DBA uses insert triggers to set all table identity fields which are defined as NUMBER(9) NOT NULL. The Modeller defines as int32 and tries to insert will a zero causing and duplicate primary key db exception. For identity fields can I tell the framework not to supply a value but fetch the the new ID value after the insert. There are also several other fields not supplied with values requiring synchronization after insert or update (last update, version ect.) how is this done?

Devart Team
Posts: 7964
Joined: Thu 14 Aug 2008 12:44

Post by Shalex » Tue 14 Oct 2008 09:43

When creating a model in Schema Modeler, try setting the following properties for the ID column:
1. Auto Generated Value to True
2. Auto-Sync to Always
Other columns, whose values are generated in database, should have the same properties set.

Post Reply