Subject | Re: [ib-support] How to delete all rows? |
---|---|
Author | David K. Trudgett |
Post date | 2002-01-03T23:25:55Z |
On Thursday 2002-01-03 at 19:10:22 -0300, Clément Doss wrote:
and re-creating it. There are some problems with this, though:
1. It's not multi-user/transaction friendly, so you probably need
exclusive access to the database.
2. It uses up a database resource that is not reclaimed until the
database is backed up and restored. This is probably not a problem
provided you back up and restore occasionally, and are not dropping
and re-creating the table too often.
3. Integrity constraints (foreign keys) might make the whole process
very bothersome.
4. It's not really "the right" way to do it.
David Trudgett
> Is there a way to delete ALL the records from a table REALLY fast.Under some circumstances, you could get away with dropping the table
> In SQL Server there is a TRUNCATE TABLE MyTable function that is
> very fast How can I do that in FB RC2?
and re-creating it. There are some problems with this, though:
1. It's not multi-user/transaction friendly, so you probably need
exclusive access to the database.
2. It uses up a database resource that is not reclaimed until the
database is backed up and restored. This is probably not a problem
provided you back up and restore occasionally, and are not dropping
and re-creating the table too often.
3. Integrity constraints (foreign keys) might make the whole process
very bothersome.
4. It's not really "the right" way to do it.
David Trudgett