sql server - Stringe timeout trigger error -


i've trigger in sql server database strange behavior, these strange instructions:

... exec  [ope].[spmissiondepartment] @aircraftid = @vnaircraftid  raiserror('test error', 16, 1)  end try  begin catch     select @errormessage = error_message()      rollback transaction      raiserror(@errormessage, 16, 1) -- strange line  end catch 

the strange behavior this:
if remove strange line receive in web page error

timeout expired. timeout period elapsed prior completion of operation or server not responding.

otherwise, if don't remove strange line, receive error

test error

there no other triggers, exec should last statement executed, how possible receive timeout without raiserror?

errors unaffected try…catch construct try…catch constructs not trap following conditions:

  1. warnings or informational messages have severity of 10 or lower.
  2. errors have severity of 20 or higher stop sql server database engine task processing session. if error occurs has severity of 20 or higher , database connection not disrupted, try…catch handle error.
  3. attentions, such client-interrupt requests or broken client connections.
  4. when session ended system administrator using kill statement.

the following types of errors not handled catch block when occur @ same level of execution try…catch construct:

  1. compile errors, such syntax errors, prevent batch running.
  2. errors occur during statement-level recompilation, such object name resolution errors occur after compilation because of deferred name resolution.

Comments

Popular posts from this blog

php - Permission denied. Laravel linux server -

google bigquery - Delta between query execution time and Java query call to finish -

python - Pandas two dataframes multiplication? -