>>I think the trigger fires with INSERT INTO but you have to be careful what you are inserting. If you are setting something like a unique primary key the INSERT INTO will err because INSERT INTO has already violated the uniqueness of the field, if, it is not specified in the VALUES list or a memvar. INSERT INTO puts a null value anywhere VALUES is not specified for a field. This why I continue to generate index keys with a global routine .vs a stored procedure.
>>
>
>More missinformation...
>
>I have a file with an ID key that has a default value of newid()... function NEWID is a stored procedure...
>
>I do...
>
>INSERT INTO EEMAST (empnum) values ('12345')
>
>And, after the insert I look around... I find that the ID field has the next id value in it, and my audit log function, called from the trigger, has logged the inserti, including the key value from id.
>
>BOb
Is the ID unique or is it set to not accept null values?
Eric
Previous
Next
Reply
View the map of this thread
View the map of this thread starting from this message only
View all messages of this thread
View all messages of this thread starting from this message only