List:General Discussion« Previous MessageNext Message »
From:Sasha Pachev Date:July 11 1999 9:44pm
Subject:Re: optimising a query
View as plain text  
Adam Powell wrote:
> 
> Hi there... I was just wondering about the database processing overhead in
> each of the following situations.  Basically I have a database of banners
> (for an ad rotation script) that I want to SELECT from.  The load on the
> database server got to high when I selected from ALL of them, so I split
> them up into 4 sections and in 4 individual scripts did :
> 
> SELECT * FROM banners WHERE section=1
> SELECT * FROM banners WHERE section=2
> SELECT * FROM banners WHERE section=3
> SELECT * FROM banners WHERE section=4
> 
> This helped get the load back down again.  However now I have come to a
> point where I have to actually revert back to my old method as there are a
> few more things I wish to do, targeting functions that must include the
> whole range of banners.
> 
> Could anybody give me some pointers, and some tips in table design that will
> speed up SELECT * FROM banners.... are there any column types to avoid?  We
> need to do about 200 lookups a second, and there are 160 rows in the
> table...
> 
> Adam
> 

Post the output of

DESCRIBE banners

to help us have a more meaningful discussion.

-- 
Sasha Pachev
http://www.sashanet.com
Thread
optimising a queryAdam Powell11 Jul
  • Re: [PHP3] optimising a queryPaul DuBois11 Jul
    • Re: [PHP3] optimising a queryAdam Powell11 Jul
      • Re: [PHP3] optimising a queryAriel11 Jul
    • Re: [PHP3] optimising a querySasha Pachev12 Jul
    • Re: [PHP3] optimising a queryAdam Powell12 Jul
    • Re: [PHP3] optimising a querySasha Pachev12 Jul
  • Re: optimising a querySasha Pachev12 Jul