SQL/Python question -- slow... What is the fixed cost?

Ignacio Vazquez-Abrams ignacio at openservices.net
Fri Oct 5 02:13:09 CEST 2001

On Thu, 4 Oct 2001, Leonardo B Lopes wrote:

> Me DB is in 3NF. And I know that 83K isn't that big, but it is big
> enough to make a query last .0008 cpusec. when joined w/ 2 other tables
> (That is the actual amount, before rounding). The problem is that a
> query on a table with only 12 items also takes about the same time. So I
> need to know how much time the library is using for data checking,
> network connection, etc...

Speaking of which, what happens if you use MySQL's socket instead of TCP/IP?

>  [snip]
> Apparently, .0004 is a Lower Bound on how fast a query can be, and that
> is not good news for me.

Yeah, but you've still only tested with a single client.

>  [snip]
> So even with a temporary table always in memory, the overhead hasn't
> changed much. Comments?

MySQL is pretty good at keeping the relevant data in memory, so there
shouldn't be much if any gain that way.

Ignacio Vazquez-Abrams  <ignacio at openservices.net>

More information about the Python-list mailing list