I need to build a sql server db trigger to update a date field with the current date when a record is inserted or updated, I think. I will be using the date field as a way to recognize updates/inserts programmatically. I went to sql server mngt studio and navigated to the database in the tree view >> opened up the programmability folder >> opened up the Trigger folder and right clicked >> Create new trigger >> I then copied the below sql into the window and hit F5. It messaged back to me that the command was successful but when I tried to open the Triggers folder I didn't see it there. When I tested in arcmap inserting a record I did not get the date updated to my date field.
What am I doing wrong and are there special considerations for creating Insert/Update/Delete triggers against SDE? Thanks...the sql is below.
>CREATE TRIGGER t_I_TestTable >ON dbo.TestTable >FOR INSERT >AS > >UPDATE TestTable SET TestTable.LastUpdated = Getdate()