Re: Error Handing



AFAIK, You cant do that.

Thanks
Hari
SQL Server MVP


"msnews.microsoft.com" <Noor> wrote in message
news:utkGW3TkFHA.3288@xxxxxxxxxxxxxxxxxxxxxxx
>I have created the stored procedure and I want to handle the error like
>
> Create Procedure MytablePro
> as
> select fld1, fld2 from mytable
> GO
>
>
> EXEC MytablePro
>
> if some one changed the table name at the back end then I have to give
> problem error but right now when procedure execute it gave me like this
> Server: Msg 208, Level 16, State 1, Procedure SPSelectBedRoom_New, Line 15
> Invalid object name 'mytable'.
>
> I want to make it proper way... can any one help... what sort of
> amendament in the stored procedure.
>
> Thanks
>


.



Relevant Pages

  • Re: Code for Scripts
    ... Hari ... SQL Server MVP ... > I'm looking for code that will create a script of a stored procedure vs. ...
    (microsoft.public.sqlserver.mseq)
  • Error Handing
    ... I have created the stored procedure and I want to handle the error like ... Create Procedure MytablePro ... select fld1, fld2 from mytable ... EXEC MytablePro ...
    (microsoft.public.sqlserver.clients)
  • Re: Error Handing
    ... > SQL Server MVP ... >>I have created the stored procedure and I want to handle the error like ... >> Create Procedure MytablePro ... >> problem error but right now when procedure execute it gave me like this ...
    (microsoft.public.sqlserver.clients)
  • Re: Stored procedure to drop and create table for end user
    ... >>> such) so the only thing the end user has access to is execute permission ... >>> back with select permission not granted on a table the stored procedure ... >> Probably because you are using dynamic SQL. ... >> Tibor Karaszi, SQL Server MVP ...
    (microsoft.public.sqlserver.programming)
  • Re: Assertion: SQL Server 2000 cant issue a SOAP call
    ... Calling it directly might not be supported, but there's no reason a remoting ... > It might be worth mentioning that calling CLR code from SQL Server is not ... > Tibor Karaszi, SQL Server MVP ... >> from a stored procedure, or from an extended stored procedure, but I ...
    (microsoft.public.sqlserver.programming)