Subject Re: [ib-support] Delete first 100 from table
Author Don Gollahon
Our largest database so far is about 6 GB. It has 10 million+ records in it
for 2 months data (we keep 2 months on hand at a time). So around 170,000
records per day. That is still too many to delete by the day. Maybe by the
hour would work.

Thanks for the idea.


"Lester Caine" <lester@...> wrote in message
news:<3EE6CBF0.9020309@...>...
> > I thought of something similar to that but I think both would be too
slow.
> > My tables can have 10 to 20 million records in them. I want to delete
those
> > that are over 2 months old but since there could be a million records to
> > delete I want to delete them 100 at a time so the FB engine can process
> > commands from other users on other databases.
>
> A million on each day? Just do a day at a time?
>
> Mine is not so bad in terms of numbers of records, but what
> do is TIMESTAMP each new record as it is added, and then
> just delete an hours worth at a time. I just keep 24 hours
> worth of live data, and the rest goes into a history table
> which just stores a shorter record for later reference. Only
> hundreds of records, but the result is very fast.
>
> --
> Lester Caine
> -----------------------------
> L.S.Caine Electronic Services
>
>