Subject Re: [IBO] Database file size increases heavily
Author Arno Garrels
Sven, Lester,

Sounds logical, but I'm rather sure, there are no open transactions when I
start a loop.

All datasets are set to AutoCommit. I also tested some explicit transactions
without a change.
Each 58 sec. I create and start a worker thread (if it isn't running).
In thread context I do:
Create a data module with session, database, tables and one query.
Connect, open datasets, fill the tables from a 'select query', query is
closed.
Iterate thru, update and delete records etc.. The two tables that are
populated/and emptied are never touched from anywhere else!
Close datasets, disconnect and destroy the data module.
Thread terminates and is freed successfully.

I start with a 1000 KB file, after around 3-4 loops, file grows to 1036 KB,
after 10 hours it's 5.5 MB.

Do you think explicit transaction handling will solve it?

regards
Arno Garrels



----- Original Message -----
From: "Svein Erling Tysvaer" <svein.erling.tysvaer@...>
To: <IBObjects@yahoogroups.com>
Sent: Monday, December 02, 2002 8:20 AM
Subject: Re: [IBO] Database file size increases heavily


> Just adding to Lesters comment. Unless there is some open transaction
> preventing the OAT to move on, FB will reuse allocated space. I.e. if you
> do add records so that your database grows from 5 to 50 Mb and then delete
> them, the database will not shrink back to 5 Mb, but the 45 Mb will be
> reused for your next insert.
>
> If there is any open transaction, reusing space is not possible and the
> size will continue to increase for every insert. Hence, always make sure
to
> avoid transactions running for a long time.
>
> Set
>
> At 15:36 01.12.2002 +0100, you wrote:
> >Hi all,
> >
> >My Firebird database file size increases heavily although I just store
> >records temporarily. Each 58 seconds two tables are filled and emtyed
> >afterwards plurally. In my tests, amount and size of data is always
exactly
> >the same. The only way to squeeze it, is backup and restore using gbak.
But
> >gbak -r needs a closed database and my app. must run 24/7. Tables are
> >accessed by IBO's Table component. Is there any workaround?
> >
> >Thanks in advance
> >Arno Garrels
>
>
>
>
___________________________________________________________________________
> IB Objects - direct, complete, custom connectivity to Firebird or
InterBase
> without the need for BDE, ODBC or any other layer.
>
___________________________________________________________________________
> http://www.ibobjects.com - your IBO community resource for Tech Info
papers,
> keyword-searchable FAQ, community code contributions and more !
>
> Your use of Yahoo! Groups is subject to http://docs.yahoo.com/info/terms/
>
>
>