Query result

db , sql server India
  • 12 years ago

    Hi

    I have a table contains(15 fields) only 7000 records, table having primary key, indexing perfect.

    when I used connect database server through internet using IP address , while runing a small query like (select * from table)  in query analyzer, its taking 40 second to get the result... why its taking that much time of time to respond. What need to be done to get faster performace. Please help me out.

  • 12 years ago

    Personally, I don't regard 'Select * from table' over 7000 rows and 15 columns to be a 'small query'. If you're returning 7000 in query analyzer, you have to accept that it's going to take longer if the database server is on the other side of the internet than on your LAN. Supposing that each row contains 4k of data, 7000 rows equates to over 25Mb and 40 seconds is not an unreasonable amount of time.   

    The best thing you can do to increase performance is to do more towards returning just the data that you need.

Post a reply

Enter your message below

Sign in or Join us (it's free).

Contribute

Why not write for us? Or you could submit an event or a user group in your area. Alternatively just tell us what you think!

Our tools

We've got automatic conversion tools to convert C# to VB.NET, VB.NET to C#. Also you can compress javascript and compress css and generate sql connection strings.

“Beware of bugs in the above code; I have only proved it correct, not tried it.” - Donald Knuth