Troubleshooting
Problem
Following error is thrown when enabling Ordered Notification and one of the table column is with IDENTITY datatype:
+---
[ART.116.3038] Adapter Runtime (Notification): Error in Notification Callback:enableCallback notification IdentityIssue.notification:OrderIdentityNotification.
[ADA.1.316] Cannot execute the SQL statement "CREATE TRIGGER #TriggerName ON #TableName for insert as begin DECLARE @col1 bigint identity, @col2 nchar(10)
DECLARE c CURSOR FOR SELECT col1, col2 FROM inserted
OPEN c
FETCH NEXT FROM c INTO @col1, @col2
WHILE @@FETCH_STATUS = 0 BEGIN
INSERT INTO #BufferTableName default values;
INSERT INTO #TriggerName (col1, col2, wm_rowid) VALUES (@col1, @col2, @@IDENTITY);
FETCH NEXT FROM c INTO @col1, @col2
END
CLOSE c
DEALLOCATE c
END
". "
(S0001/156) Incorrect syntax near the keyword 'identity'."
Incorrect syntax near the keyword 'identity'.
---+
Document Location
Worldwide
Log InLog in to view more of this document
Historical Number
Product Build 6.5
Was this topic helpful?
Document Information
Modified date:
20 March 2025
UID
ibm17205692