Tricky question ob querys, how to solve ???
-
In a Stored Procedure sp { ... .. Query1 Query2 Query3 .... .. } Here in the above storedprocedure the Query2 should be exceuted whenever the Query1 fails and Query3 should be executed invariable the above condition.
-
In a Stored Procedure sp { ... .. Query1 Query2 Query3 .... .. } Here in the above storedprocedure the Query2 should be exceuted whenever the Query1 fails and Query3 should be executed invariable the above condition.
its been a long time since i programmed in C# but you could do this try { query1 catch try { query2 catch try { query3 catch messageBox(error) } } } Something to that effect.
-
In a Stored Procedure sp { ... .. Query1 Query2 Query3 .... .. } Here in the above storedprocedure the Query2 should be exceuted whenever the Query1 fails and Query3 should be executed invariable the above condition.
Inside your stored procedure you could do the following:
INSERT INTO ... (Query 1) IF @@Error <> 0 BEGIN INSERT INTO .... (Query 2) END UPDATE ... (Query 3)
the last thing I want to see is some pasty-faced geek with skin so pale that it's almost translucent trying to bump parts with a partner - John Simmons / outlaw programmer
Deja View - the feeling that you've seen this post before. -
its been a long time since i programmed in C# but you could do this try { query1 catch try { query2 catch try { query3 catch messageBox(error) } } } Something to that effect.
He wanted to do all that in a stored procedure.
Upcoming Scottish Developers events: * Glasgow: Tell us what you want to see in 2007 My: Website | Blog | Photos
-
Inside your stored procedure you could do the following:
INSERT INTO ... (Query 1) IF @@Error <> 0 BEGIN INSERT INTO .... (Query 2) END UPDATE ... (Query 3)
the last thing I want to see is some pasty-faced geek with skin so pale that it's almost translucent trying to bump parts with a partner - John Simmons / outlaw programmer
Deja View - the feeling that you've seen this post before.Yes i wanted to do it all in Stored procedure, Thanks a lot Pete