Question : Deadlock When Doing Begin and Commit Transaction.

Hi,

I have a Begin and Commit Transaction to write data to sql.

What I want to do is if the data is not exist than I do insertion otherwise I do updating.

For the first round it is ok, but for the next data the when I try to check if data is exist or not then it is hanging until time out expired (I use aspx form).

How to solve this problem?

Thank you.

Answer : Deadlock When Doing Begin and Commit Transaction.

As long as the transaction and all queries in side it use one connection, it's ok. it doesn't matter if you (re)use it in other places.
Random Solutions  
 
programming4us programming4us