Hi
I am using PgSqlLoader to Insert records into a table on a remote server.
The table we are writing to has an AutoIncrement field as its PK. We are using pgLoader.SetValue("FieldName", value) on all other fields to set its value and expecting the auto increment field to increment and update automatically. We can manually set the auto increment field in the code as above but this defeats the object.
On calling pgLoader.NextRow(); and then pgLoader.Close(); raises an exception null value in column "OIDIdcCount" violates not-null constraint
The table field in the schema is setup as "OIDIdcCount" serial NOT NULL
with the default value/sequence set to
nextval('"TblIdcCount_OIDIdcCount_seq"'::regclass)
Any ideas?
Many thanks in advance for your help
Stephen
PgSqlLoader Insert, SetValue, AutoIncrement PK field
-
- Posts: 10
- Joined: Mon 18 Jan 2010 10:48
- Location: Devon, UK
New version of dotConnect for PostgreSQL 5.50 is released!
It can be downloaded from http://www.devart.com/dotconnect/postgr ... nload.html (trial version) or from Registered Users' Area (for users with valid subscription only): http://secure.devart.com/ .
For more information, please refer to http://www.devart.com/forums/viewtopic.php?t=21944 .
It can be downloaded from http://www.devart.com/dotconnect/postgr ... nload.html (trial version) or from Registered Users' Area (for users with valid subscription only): http://secure.devart.com/ .
For more information, please refer to http://www.devart.com/forums/viewtopic.php?t=21944 .
-
- Posts: 10
- Joined: Mon 18 Jan 2010 10:48
- Location: Devon, UK