Subject | Re: Slow 1st query |
---|---|
Author | menjit_singh |
Post date | 2005-12-21T05:06:27Z |
Hello all, i need help with embedded.
master table that keeps track of which stock are stored in which
table. Still the problem happens. This is the problem:
1. After a reboot, when it does the first query, it is so slow (about
1. minute, down from 1.5 minute earlier). Disk activity is very high.
2. After it have 'discovered' the tables and the index, it is super
fast.
i have also created 26 tables with no index at all. the first query
is still slow (about 45 to 60 seconds). next qeury is fast, but not
as fast as with index.
All of this happen after a reboot. if i launch the application often,
without reboot, the qeury time gets less and less.
please advice..
> >i have tested with 26 tables with 2 index on each tables. i have a
> > CREATE TABLE DATA (
> > STOCK VARCHAR(55),
> > SYMBOL VARCHAR(8),
> > DATA DATE,
> > OPN FLOAT,
> > HIGH FLOAT,
> > LOW FLOAT,
> > CLS FLOAT,
> > VOL FLOAT);
> >
> > /* Indices */
> >
> > CREATE INDEX DATA_1DX1
> > ON DATA(STOCK);
> > CREATE INDEX DATA_IDX2
> > ON DATA(SYMBOL);
> > CREATE INDEX DATA_IDX3
> > ON DATA(DATA);
> >
> >
> > Total records: 800,000 rows, 8 fields.
> >
> > exact query: SELECT STOCK FROM DATA GROUP BY STOCK ORDER BY STOCK
> >
> > pc spec: p4 2.4, 512 mb
> >
> > I appreciate the help. Thanks.
master table that keeps track of which stock are stored in which
table. Still the problem happens. This is the problem:
1. After a reboot, when it does the first query, it is so slow (about
1. minute, down from 1.5 minute earlier). Disk activity is very high.
2. After it have 'discovered' the tables and the index, it is super
fast.
i have also created 26 tables with no index at all. the first query
is still slow (about 45 to 60 seconds). next qeury is fast, but not
as fast as with index.
All of this happen after a reboot. if i launch the application often,
without reboot, the qeury time gets less and less.
please advice..