Hi all,
I am using raiserror with nowait for the first time but I am not having the expected behaviour.
i.e. if I run the following, I should have the first message immediatley and the second one after 5 secs, but both messages are appearing at the end of the procedure run (as if NOwait is being ignored)
RAISERROR ('DELAY 1 HAS ENDED', 10,1) WITH NOWAIT
WAITFOR DELAY '00:00:05.00'
RAISERROR ('DELAY 2 HAS ENDED', 10,1) WITH NOWAIT
I tried this on different SQL Servers (2005/2008) with the same behaviour.
Am I missing something obvious?
Thanks a lot
Benoit
I am using raiserror with nowait for the first time but I am not having the expected behaviour.
i.e. if I run the following, I should have the first message immediatley and the second one after 5 secs, but both messages are appearing at the end of the procedure run (as if NOwait is being ignored)
RAISERROR ('DELAY 1 HAS ENDED', 10,1) WITH NOWAIT
WAITFOR DELAY '00:00:05.00'
RAISERROR ('DELAY 2 HAS ENDED', 10,1) WITH NOWAIT
I tried this on different SQL Servers (2005/2008) with the same behaviour.
Am I missing something obvious?
Thanks a lot
Benoit