Viewing 7 posts - 361 through 367 (of 367 total)
Now I have more time to write some details and example. Here it is:
-- Works from sql2000 up
declare @sqlWithoutConcatenation nvarchar(4000)
-- We used parameter @id two times, and @date one time....
December 31, 2010 at 10:56 am
Instead of exec(@tsql) please use sp_executesql with values passed as parameters - do not concatenate values!
December 30, 2010 at 8:22 pm
Operation = triggering operation (insert,update,delete)
N = number of rows you inserted,updated or deleted in triggering table
#Rows INSERTED = number of rows in INSERTED pseudo-table the trigger code will see
#Rows DELETED...
December 29, 2010 at 8:14 am
I would do something like this:
declare @comment1 varchar(100), @comment2 varchar(100)
if exists(select 1 from inserted)
if exists(select 1 from deleted) select @comment1 = 'updated - new', @comment2 = 'updated -...
December 29, 2010 at 6:47 am
No. It's not a bug to create a table with FK, it is very good, and very recommended and anything else would be "bug".
The sole purpose of constraints is to...
December 28, 2010 at 12:55 am
If you do not want error message for violating foreign key and do not want to use ON DELETE CASCADE, in Task 1 you should handle the case when there...
December 27, 2010 at 1:01 am
Transaction log records all changes in db (insert,update,delete, create index, etc, but NOT select's for example) and you can roll it back or forward in time IF you are in...
December 17, 2010 at 1:15 am
Viewing 7 posts - 361 through 367 (of 367 total)