Slow Query

  • Hi,

    I have a very weird senario. I have 1500000 rows to load into a sql server 2005 table. The table has a serial number which is a char(17) and looks like this '0000012356743517' and is indexed. When you load the data into Sql its quick. Then the nightmare begins

    They are four statements

    1. select ......

    2. insert into.....

    3. Open a socket to another system and read "this takes 1.5s per record"

    3. update .....

    Frm java side they are multithreading and its set to 12. This is creating a lot of locks and is like writing 400 rows per second. I switched off the autoshrink option and re-organised the indexes. I still dont understand why its not fast...

    How can I make this fast ? The sql code is embbeded into the java app. I believe its bad practice but the developers are adamant to keep it there.

    How do I get rid of the locks, increase my processing speed and track the speed of the number of rows processed per minute.

    Ranga

  • You aren't giving us anywhere near enough information. Please read this article on how to post performance problems:http://qa.sqlservercentral.com/articles/SQLServerCentral/66909/

    (edit: typos)

    [font="Times New Roman"]-- RBarryYoung[/font], [font="Times New Roman"] (302)375-0451[/font] blog: MovingSQL.com, Twitter: @RBarryYoung[font="Arial Black"]
    Proactive Performance Solutions, Inc.
    [/font]
    [font="Verdana"] "Performance is our middle name."[/font]

  • I agree with Barry. If you post the necessary information outlined in the article, the answers you are given will be less guesswork and more usable by you.

    Jason...AKA CirqueDeSQLeil
    _______________________________________________
    I have given a name to my pain...MCM SQL Server, MVP
    SQL RNNR
    Posting Performance Based Questions - Gail Shaw[/url]
    Learn Extended Events

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply