Forum Replies Created

Viewing 7 posts - 361 through 367 (of 367 total)

  • RE: Dyanmi SQL

    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....

  • RE: Dyanmi SQL

    Instead of exec(@tsql) please use sp_executesql with values passed as parameters - do not concatenate values!

  • RE: Update trigger is not working

    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...

  • RE: Update trigger is not working

    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 -...

  • RE: Foreign Key Problem

    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...

  • RE: Foreign Key Problem

    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...

  • RE: Slight Problem :(

    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...

Viewing 7 posts - 361 through 367 (of 367 total)