isc_dsql_exec_immed2 with zero transaction handle could lead to a BUGCHECK(147) [CORE3389] #3755
Submitted by: @hvlad
I developing a tests using two transactions in the same attachments and found this bug.
DDL: CREATE GLOBAL TEMPORARY TABLE T2 (ID INT) ON COMMIT PRESERVE ROWS
tx1: SET TRANSACTION READ COMMITTED NO VERSION NO WAIT
tx1: INSERT INTO T2 VALUES (1)
tx2: SET TRANSACTION SNAPSHOT NO WAIT
It was expected to got "invalid transaction handle" error there, not a bugcheck.
Note, i wrongly used "NO VERSION" instead of "NO RECORD_VERSION" therefore start of tx1 failed.
The text was updated successfully, but these errors were encountered:
Commented by: @hvlad
Before DSQL was integrated into the engine in v2.5 it was y-valve who throws isc_bad_trans_handle.
In v2.5 DSQL called engine directly and few checks for valid transaction was introduced at metd.epp.
In HEAD some checks performed before search in DSQL cache (at least in METD_get_relation) so,