Subject Re: [ib-support] Slow view to China
Author Jason Chapman (JAC2)
""daxydoggie"" <craigturner@...> wrote in message
> Hi
> Our set up
> Server:IB6 db
> Clients:W98/W2K
> Delphi App/BDE/IB5.x client
> The strange thing is this;
> we have a view set up that joins 2 tables clients and vehicles, if
> you search by registration no from the app i.e.
> select * from view where regno like 'P35%' , generally the results
> come back sub second. This uses an index.
> On Tuesday, this search started taking 20-30 secs and is getting
> worse.
> This same query from a vb app/ado/dsn/odbc/IB5.x client takes about a
> second, as does using the IB ISQL app.
do you mean to the same DB or another DB?

> We've taken the db down and brought it back up to ensure index stats
> are reorg'd and garbage is collected etc and this doesn't help.
That won't restat the indices AFAIK. You either have to set index or
deactivate and reactivate.
have you done a gfix to test the integrity of the databases.

I would:
1) Take an OS backup when the DB is offline, i.e. IB/FB is not connected
(this is you Oh my god its exlpoded backup).
2) Run gfix to ensure the index / data is not corrupt
3) re-set the indices to rebuild the selectivity
4) Check the DB stats to ensure there isn't a really old transaction lurking