1 row insert in specific table  timeout

Posted on 2007-08-07
Last Modified: 2013-11-05
I have an ASP web application which has been running for the past 2 years with no problems. Today it started giving a timeout error when inserting 1 row into a table. Other inserts into tables are running fine.

Error: -2147217871 / [Microsoft][ODBC SQL Server Driver]Timeout expired / Microsoft OLE DB Provider for ODBC Drivers

Related SQL statement: insert into pchldr (plcyid_ph, lastname_ph, firstname_ph, address1_ph, address2_ph, city_ph, state_ph, zip_ph, county_ph) values (137305,'TEST','TEST','test','test','test','TS','55555','Test')

Description: [Microsoft][ODBC SQL Server Driver]Timeout expired
Help context: 0
Help file:
Native error: 0
Error number: -2147217871
Error source: Microsoft OLE DB Provider for ODBC Drivers
SQL state: S1T00

Any thoughts on what could cause this simple insert to start failing all of the sudden? The table has a Key on an ID field and only about 22K records in it.
Question by:Darksbane
    LVL 18

    Expert Comment

    by:Sham Haque
    could be that a constraint is being violated by new inserts:

    check for the following:
    unique or check constraint
    primary key
    foreign key
    field size

    try copying the table (use SELECT * INTO NEW_TABLE WHERE 1=0)
    and try your same insert against the new table
    LVL 8

    Expert Comment

    what is the data type of your zipcode column. you are entering '55555' which is a string. if the datatype of that column is INT. then you wont be able to enter. you sould remove the quotes ( just 55555)..
    check for this
    LVL 42

    Expert Comment

    There is probably another insert transaction in progress that is blocking additional inserts.  Find that transacation and commit, rollback, or kill it.  I would start by looking at the locks that are being held on the table in question.

    Expert Comment

    What is so difficult that the geniuses in Redmond can't simply return an error that means something?  Is their networking software that bad that they can't decipher the real error?   Any other endeavour in the world would have failed miserably, if it weren't for the criminal use of advertising promotion by MSFT, they would(should) have gone down as well.
    LVL 1

    Accepted Solution

    PAQed with no points refunded (of 500)

    EE Admin

    Featured Post

    Gigs: Get Your Project Delivered by an Expert

    Select from freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely and get projects done right.

    Join & Write a Comment

    I recently came across an interesting Question In EE ( and was puzzled about how to achieve that using SSIS out of the box tasks, which was i…
    For both online and offline retail, the cross-channel business is the most recent pattern in the B2C trade space.
    Viewers will learn how the fundamental information of how to create a table.
    Viewers will learn how to use the SELECT statement in SQL to return specific rows and columns, with various degrees of sorting and limits in place.

    754 members asked questions and received personalized solutions in the past 7 days.

    Join the community of 500,000 technology professionals and ask your questions.

    Join & Ask a Question

    Need Help in Real-Time?

    Connect with top rated Experts

    25 Experts available now in Live!

    Get 1:1 Help Now