Re: After RAISERROR executes next line.

Tech-Archive recommends: Repair Windows Errors & Optimize Windows Performance

From: Thomas Kejser (thomas_at_kejser.org)
Date: 01/02/05


Date: Sun, 2 Jan 2005 14:49:54 +0100

Hi Prasanth

If I understand you correctly you want to raise an exception so that the
print statement is NOT executed?. Is this correct?

Yours Sincerely
Thomas Kejser

"Prasanth" <Prasanth@discussions.microsoft.com> wrote in message
news:895177B6-342D-4F65-8D66-4177C56B8F6E@microsoft.com...
> Hello,
>
> I am trying to raise an error in MS SQL Server 2000 using the lines
> if x = 1
> raiserror('Error Message', 10, 1)
> print 'Next Line.'
> But, on execution, it shows the error message and goes to the next line.
> (prints 'Next Line')
> How do I set up the server so that after raising the error, the control
> goes
> to the called program.
>
> Thanks in advance,
> Prasanth



Relevant Pages

  • After RAISERROR executes next line.
    ... I am trying to raise an error in MS SQL Server 2000 using the lines ... But, on execution, it shows the error message and goes to the next line. ...
    (microsoft.public.sqlserver.server)
  • Re: Importing functions that require parameters
    ... As a python module is executed when ... To prohibit execution ... Now the print statement will be executed if you invoke your script from ...
    (comp.lang.python)
  • Re: Whats up with this compiler hint?
    ... The "Raise;" statement will transfer execution to the parent exception handler. ... Even though the function result is already assigned, the execution never reached the end of function block and the function result is never returned. ...
    (comp.lang.pascal.delphi.misc)
  • Re: getting name of passed reference
    ... from traceback import extract_stack ... raise None ... frame = sys._getframe ... the print statement returns the full function call including ...
    (comp.lang.python)
  • raise and rescue
    ... Is is possible to raise an exception then rescue it and then go back to ... whereever it was raised and continue with execution? ...
    (comp.lang.ruby)