• lewisdow123 (4/17/2013)


    Hi,

    I have a standard update statement that updates one row at a time. The table size is 340,000 rows, so it's large but it's not huge.

    The first time I run the query it takes a very long time considering its a simple update, around 40 seconds. However the second time I run the same update statement it takes less than a second.

    I just wondered if anyone might be able to assist in letting me know where I might be able to start looking to find out why the update statement is so slow?

    Any help would be appreciated.

    Thanks,

    Lewis

    Hi there,

    The part of your question that worries me is "updates one row at a time".

    Your best bet is to follow the advise in this article about how to post a performance problem[/url]. It'd make it much easier to point you in the right direction, or perhaps even suggest improvements.

    Thanks.


    Forever trying to learn
    My blog - http://www.cadavre.co.uk/
    For better, quicker answers on T-SQL questions, click on the following...http://www.sqlservercentral.com/articles/Best+Practices/61537/
    For better, quicker answers on SQL Server performance related questions, click on the following...http://www.sqlservercentral.com/articles/SQLServerCentral/66909/