Question

'ERROR: null value in column "objectid" violates not-null constraint - postgres/ArcSDE

  • 27 March 2020
  • 2 replies
  • 52 views

Badge +5

Hi,

I have an ArcSDE geodatabase on postgres. Im using a feature writer to insert records in an existing feature class.

While doing so, I get the below error 'ERROR: null value in column "objectid" violates not-null constraint'

When I drop the table and create new while writing, I get no errors.

Logically, the sde should autogenerate this objectid field whenever I insert a new record. Am I right or where am I going wrong?

Please suggest

Thanks


2 replies

Userlevel 2
Badge +19

That's weird.

 

 

FME ignores the OBJECTID value even if you pass it to the Writer.

Is the OBJECTID in the attribute list of your Writer? I would remove it just in case.

Userlevel 4

Are you using the POSTGRES or the GEODATABASE_SDE writer format in FME?

Only ESRI writers will automatically populate the OBJECTID values, with any other writer (e.g. POSTGRES) you will have to manually specify the value.

If you are using the GEODATABASE_SDE writer, it would be helpful if you could post the FME log here.

Reply