Ignore Execution Warning on Comment
I don't want to globally turn off warnings for UPDATE or DELETE without WHERE clause, but would like an authorization text that disables the warning in a given script:
-- Currently Warns:
DELETE FROM dbo.Person
-- Suggestion - comment would authorize the delete to not warn
/* Authorized */
DELETE FROM dbo.Person
-
Jim commented
I completely agree. Sometimes I get a false positive (like when there's a join involved) or during a conversion script. It would be great to just say "Yes, I have looked at this and it's fine in this case"
I was going to suggest comment bracketing like you do with "-- SQL Prompt formatting off/on", but a one-off comment would work fine too.