SQL transaction timeing out problem
Posted on 2009-07-02
Hi i am using vb.net vs2008. I have a command object which executes a simple update statement on a table that has 100 000 records in it.
For some reason today it has started timeing out which it has not done before
I then took the UPDATE statement and ran it on SQL management studio and it is timing out there now as well.
UPDATE tblACBTrans set Status = 'Rejected' , UnpaidDate = '2009/07/02' where AutoID = 2829442;
I have created a separate Index non-clustered Unique index on my field AutoID which is also my primary key for this table. Still no joy
This is my code in vb to execute the statement, i tried setting the CommandTimeOut property to 60 but did not help
Dim command As New SqlCommand(SQLString, cn)
command.CommandTimeout = 60
If cn.State = ConnectionState.Broken Or cn.State = ConnectionState.Closed Then cn.Open()
If cn.State = ConnectionState.Open Then
ModifyData = "Success"
Catch exSQL As SqlException
command = Nothing
thanks, any help would be great