Subject Re: Please. A solution with TRANSACTIONS for multiple inserts (AAge)
Author pepmallorca
Hello:

I'll prove the solution to insert all the distinct words in a table.
The result time is a little better, but after I have to do the SELECT
GROUP BY, to do the correct insert. I don't know how time it spends.

It's a good idea, but my general problem is a litte more complex and
I think that the overhead to do the insert of all the words (the
space of the database is increased in more more of MB), then the
insert, and then the delete of the temporal table, I think is too
much overhead for my general problem.

I'll save your idea, for other problems that I could find it.

I don't understand when you say that using ONE SINGLE TRANSACTION IB
uses a simple compression. I supposse IB_transaction1 in my program
is a Single Transaction.

Thank Aage,



--- In IBObjects@y..., Aage Johansen <aagjohan@o...> wrote:
> You wrote:
> Your idea is not bad (I'll test it), but the pair INSERT-
> UPDATE I think is very fast, the problem will be the writes to the
> disk another time (and now the 8MB is possibly will be 22MB or
> more)...
> -----------------
>
> When inserting in the original table you have the overhead of IB
checking
> the constraint (of the primary key). With the simple table (just
one
> field, no constraints), it might be faster.
> Run all the inserts in one single transaction (as Geoff mentions).
> As for the size, IB uses a simple compression (which might help).
>
> Regards,
> Aage J.