ASP Programming
 
Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
User Name:
Password:
Remember me
Go Back   Dev Shed ForumsProgramming Languages - MoreASP Programming

Reply
Add This Thread To:
  Del.icio.us   Digg   Google   Spurl   Blink   Furl   Simpy   Y! MyWeb 
Thread Tools Search this Thread Rate Thread Display Modes
 
Unread Dev Shed Forums Sponsor:
  #1  
Old October 14th, 2003, 10:37 AM
sanj sanj is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2003
Posts: 100 sanj User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 13 h 42 m 8 sec
Reputation Power: 6
Faster return of large recordset

Hi,

I remember reading somewhere that there is a faster way to retrieve a large recordset to display it in a table, could anyone point me in the right direction.

Thanks,

Sanjay

Reply With Quote
  #2  
Old October 14th, 2003, 11:54 AM
Doug G Doug G is offline
Grumpier Old Moderator
Dev Shed God 12th Plane (10500 - 10999 posts)
 
Join Date: Jun 2003
Posts: 10,957 Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level) 
Time spent in forums: 1 Month 1 Day 15 h 35 m 19 sec
Reputation Power: 802
Faster than what?

Reply With Quote
  #3  
Old October 14th, 2003, 12:30 PM
sanj sanj is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2003
Posts: 100 sanj User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 13 h 42 m 8 sec
Reputation Power: 6
Your right, I'm using Dreamweaver to extract 1000 records but it takes a long time to display,

The query is:
PHP Code:
 SELECT *
FROM tick_tbl
WHERE monthentry 
MMColParam 


I just wanted to know the most effeicient method for displaying these results (1000 - 1500) records with approx. 25 fields.

Thanks,

Sanjay

Reply With Quote
  #4  
Old October 14th, 2003, 04:17 PM
Doug G Doug G is offline
Grumpier Old Moderator
Dev Shed God 12th Plane (10500 - 10999 posts)
 
Join Date: Jun 2003
Posts: 10,957 Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level) 
Time spent in forums: 1 Month 1 Day 15 h 35 m 19 sec
Reputation Power: 802
You can specify the column names individually rather than use *. Generally this is a bit faster.

Look at indexing the monthentry column if it isn't.

Reply With Quote
  #5  
Old October 14th, 2003, 05:30 PM
sanj sanj is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2003
Posts: 100 sanj User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 13 h 42 m 8 sec
Reputation Power: 6
I'm retriving all the fields, should I still specify each column?

I'm looking at trying to optimise the DB,

Is there any reason why I should not index say 10 columns rather than one?

Also, should I increase the MaxBufferSize or MaxScanRows (not sure what they do) in the ODBC setup dialog?

Thanks,

Sanjay

Reply With Quote
  #6  
Old October 15th, 2003, 12:25 AM
Doug G Doug G is offline
Grumpier Old Moderator
Dev Shed God 12th Plane (10500 - 10999 posts)
 
Join Date: Jun 2003
Posts: 10,957 Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level)Doug G User rank is Major General (70000 - 90000 Reputation Level) 
Time spent in forums: 1 Month 1 Day 15 h 35 m 19 sec
Reputation Power: 802
Even if you need all the columns, specifying the column names saves the db server some work. I've read it's faster, but I don't work in heavily loaded environments often so I can't say for sure.

Indices put extra load on the server when inserting or updating, I try to index only what's necessary.

If it's your server you can try tweaking the ODBC properties.

Reply With Quote
  #7  
Old October 15th, 2003, 06:43 PM
sanj sanj is offline
Contributing User
Dev Shed Newbie (0 - 499 posts)
 
Join Date: Mar 2003
Posts: 100 sanj User rank is Just a Lowly Private (1 - 20 Reputation Level) 
Time spent in forums: 13 h 42 m 8 sec
Reputation Power: 6
Thanks Doug,

We are on a dedicated server, I just wanted some help in what options I could set to maximise performance for the DB, I've not seen anything around - any help would be welcome.

Regards,

Sanjay

Reply With Quote
Reply

Viewing: Dev Shed ForumsProgramming Languages - MoreASP Programming > Faster return of large recordset


Thread Tools  Search this Thread 
Search this Thread:

Advanced Search
Display Modes  Rate This Thread 
Rate This Thread:


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

vB code is On
Smilies are On
[IMG] code is On
HTML code is Off
View Your Warnings | New Posts | Latest News | Latest Threads | Shoutbox
Forum Jump


Forums: » Register « |  User CP |  Games |  Calendar |  Members |  FAQs |  Sitemap |  Support | 
  
 





© 2003-2008 by Developer Shed. All rights reserved. DS Cluster 1 hosted by Hostway
Stay green...Green IT