Subject Garbage creation question
Author Fulvio Senore
I am curious about a simple question. If I understand it correctly,
each time that I update a row the database keeps a copy of the original
version. When I commit, the copy becomes garbage ready for a sweep.

So, updating a row creates some garbage. If I delete the old row and
then I insert the new one this also creates some garbage, of course.

The question is: does updating a row create significantly less garbage
than deleting the row and inserting it again?

If I update a row with the same values (no change) does this cause
garbage too, or the engine is smart enough to notice that there is no

I ask this because there are situations (like the items of an order,
when the user updates the order) when it would be much simpler to delete
all the old rows and then insert all the new ones (the number of the new
rows might be different from the number of the old ones). I would like
to know how inefficient would be such a practice for the Firebird
database architecture.

Thanks in advance.

Fulvio Senore