HPCC-11261 - regression if inside transaction

Signed-off-by: Jake Smith <jake.smith@lexisnexis.com>