This might be fundamentally stupid, but here goes:
I have a stored procedure that I need to just run without throwing overflow errors. In case of an overflow, I'm happy with a NULL.
I see it suggested all around the internet (eg. here and here) to just use
SET ARITHABORT OFF;
SET ARITHIGNORE ON;
That is fine, but should I, like, turn them back on at the end of my SP?
SET ARITHABORT ON;
SET ARITHIGNORE OFF;
Like this? Are these even the defaults?
Also, Do I need both switches to get it to ignore overflow errors (in my case, trying to put '606006000' in a SMALLINT field)?
Using Azure DB v12.