I have the following code:
SELECT @OLD_VALUE = (SELECT NUMBER_OF_POS from deleted)
SELECT @NEW_VALUE = (SELECT NUMBER_OF_POS from inserted)
.
.
.
.
EXEC logEvent @BATCH_ID, @ACT, @TABLE_NAME, @COLUMN_NAME, @OLD_VALUE, @NEW_VALUE, @USER_ID
When NUMBER_OF_POS is NULL in the deleted and inserted table, the EXEC logEvent fails.
Is there a way to fix this?
Thanks.