[thelist] is there something like eval() in my sql?

Richard Bennett richard.bennett at skynet.be
Tue May 25 09:54:17 CDT 2004


On Tuesday 25 May 2004 17:08, david.landy at somerfield.co.uk wrote:
> richard,
>
> >I was hoping to avoid this, as each list is 80.000 records as it is...
>
> why were you hoping to avoid this? what database are you using, 
mySQL for this.

> and does it 
> have a maximum number of rows? on most db's (even access) if you optimise
> your indexes properly the size of the table will not be a performance
> issue, and tables with millions or tens of millions of rows will function
> just fine. try it and see.
Yes, but that means you can only query by the indexed fields.
I have the call data in a MSSql database with 7000.000 records, and it's fine 
if I query by Date or ID, but if I suddenly need a list of calls going to 
france after 9pm, or something, I can forget it.

So in the backup database (MySQL) I am saving the data in tables of finite 
size (ie one per month) which is far more flexible (I find) for gathering 
statistics..., and faster to access from the webinterface.

I have compared the two for a request filtered by primary index, and the small 
tables are far faster...

>
> >Will it be best to put all the pricelists into one big table, with
> >datefrom/dateto columns for each record, or to use a third table with the
> >datefrom/dateto columns, and link by tableID?
>
> yes, either would work. i'd recommend keeping everything in one place
> unless there's a compelling reason not to. simpler, and more elegant.
Yeah, i was just a little worried about potential problems with overlapping 
dates for the same prefix... I'll have to check for that...

>
> hth,
>
> david
Thanks for your ideas.


More information about the thelist mailing list