SQL execution problem in sql server

Dear All,

I am using dotnet 1.0 and send sql to sql server 2005 for execute. Sometimes when i send a batch of sql(e.g 6 sql statement), the sql server return success but 1 of the sql had not been executed. Does anyone has any idea on this issue or any method that i can keep track of this kind of error?

Thanks,

Johnson

December 27th, 2007 2:55pm

Hi Johnson,

if SQL server is throwing any errors then it should be sent back to calling program.

Check the execution of such batch from QA or SSMS based on SQL server version you are using.

By any chance, are you firing six different batches with one sql statement in each batch and one batch could be failing then it may depend on the error trapping routine done at your application level.

Free Windows Admin Tool Kit Click here and download it now
December 28th, 2007 12:47pm

Hi Johnson,

You need to use Transaction in .net along with exception handling. Here we have sample for framework 1.1 http://msdn.microsoft.com/en-us/library/system.data.sqlclient.sqltransaction(v=vs.71).aspx

Transaction can be handled at SQL Server level, refer http://www.codeproject.com/Articles/4451/SQL-Server-Transactions-and-Error-Handling

January 23rd, 2014 5:38am

WOW... Dot.Net 1.0 :-)
I remember it was with more bugs then insects in nest of ants :-) I think it was at 2000 and 3 month later Microsoft came-up with version 1.1 which was not much better(but at least it worked). At that time i preferred to work with ASP3 then A
Free Windows Admin Tool Kit Click here and download it now
January 23rd, 2014 6:07am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics