Question : VBA timing out on SQL Server update

I have a VBA program that has been running fine for months, but now it is timing out when attempting to update an SQL Server table. I get the message shown in the attached image.

The culprit query is:

update tblPaEmpBenefits set planCode = '001+0351634+053+00004+04300+401*EMP', lastUpdate = '08/01/2010' where recId = 12021

recId is a bigit identity field and is the primary key. Queries seem to be executing quickly enough on the SQL Server host. The server seems to be only about 10% active and there appears to be plenty of free disk space. I have no clue as to why these updates would suddenly be timing out.

The setup is: SBS 2003 server running SQL Server 2005. Windows XP and Vista wokstations (I've tried from both) running Access 2003 using ADP/ADE database connecting to SQL Server on SBS 2003.

Urgent! Thanks.
Attachments:
 
VBA timeout on SLQ Server Update
VBA timeout on SLQ Server Update
 

Answer : VBA timing out on SQL Server update

>>Nope, I tried taking your same code and putting it inside my loop and it still times out. <<
I am not surprised.  As 8080_Diver has pointed out if you want to be successful using MS SQL Server, you need to forget all the bad habits you may have picked up using MS Access including record navigation and start thinking in sets of data.  Otherwise you may just as well go back to using MS Access with DAO.
Random Solutions  
 
programming4us programming4us