Select to view content in your preferred language

Postgresql trigger example ?

1721
1
Jump to solution
09-02-2012 10:23 PM
JackZHANG
Frequent Contributor
Greetings,
Could somebody please show me an example of Trigger in Postgresql ArcSDE where if user edited feature attribute A it automatically update attribute B of the same feature?  Many thanks!
0 Kudos
1 Solution

Accepted Solutions
VinceAngelo
Esri Esteemed Contributor
There's nothing Esri-specific about PostgreSQL trigger syntax.  Wouldn't you be better off asking
in a PostgreSQL forum?  The only part that's relevant here is that the trigger would be on the adds
table if the layer was versioned.

From a quick review of the PostgreSQL documentation, it appears you'll need to choose a language
in which to implement the trigger function (from those available in your install), so there's four options
besides writing a 'C' function, and you'll want to specify which one, along with the version of PG when
you post.

- V

View solution in original post

0 Kudos
1 Reply
VinceAngelo
Esri Esteemed Contributor
There's nothing Esri-specific about PostgreSQL trigger syntax.  Wouldn't you be better off asking
in a PostgreSQL forum?  The only part that's relevant here is that the trigger would be on the adds
table if the layer was versioned.

From a quick review of the PostgreSQL documentation, it appears you'll need to choose a language
in which to implement the trigger function (from those available in your install), so there's four options
besides writing a 'C' function, and you'll want to specify which one, along with the version of PG when
you post.

- V
0 Kudos