Subject Re: table lock
Author Roman Rokytskyy <>
> I need to update a group of records and while i do that no one
> should read or update that group of record. The granularity of the
> operation should not be at record level but at group of records
> level. So i'm trying to acquire a table lock.

Simply set transaction isolation level to TRANSACTION_SERIALIZABLE.
First update will try to lock the table. IIRC, it is possible to
reserve (lock) more than one table on tx start via FB API, but this
is not available via JDBC interface.

So, as long as you are interested in one table,
TRANSACTION_SERIALIZABLE will be enough for you.

Internally TRANSACTION_SERIALIZABLE is translated into
isc_tpb_consistency, you can read more about it in API Reference.
Also you can provide your custom TPB mapping, this should be in our

Best regards,
Roman Rokytskyy