sententia
Home    Blog

Blog - Tech / Database / SqlServer

      
Jul 19 at 6:58am | 0 comments

Dec 02 at 8:06am | 0 comments
I'm very familiar with Oracle and I'm trying to find the comparable code in SqlServer world.  I think I'm confusing myself with the need or not for SET XACT_ABORT ON or BEGIN TRAN or ...
Basically, I am putting a trigger on a base table  'mytable' that upon an insert or update on mytable, to copy two values to another table 'mynewtable'.  I believe I understand how to handle that aspect but want to add error handling such that if the trigger logic fails for whatever reason, I want the insert into the base table 'mytable' to commit regardless and we write a message to another table 'myerrortable'.
Trying to find any solutions on this was onerous.

Jun 02 at 3:41pm | 0 comments
Coming from an Oracle world, a NULL and '' are evaluated the same by null functions.  Not true with SqlServer based on my searches ...

Jun 02 at 2:57pm | 0 comments
Extending my knowledge on SqlServer.  I had a need to log the number of rows I was manipulating and found this article ...

May 27 at 12:51am | 0 comments
Instead of hardcoding the name of a stored procedure when you are trying to run some DDL that need that value ...

May 27 at 12:47am | 0 comments
The following code example shows a SELECT statement that generates a divide-by-zero error. Along with the error message, information that relates to the error is returned.