[ Avaa Bypassed ]




Upload:

Command:

hmhc3928@3.22.41.80: ~ $
################################################################################
#
# UPDATE using multiple statements. Subtract a value (4) from one field, then
# add the same value to another field in the same row.
#
# Mind any tx errors, ROLLBACK if needed to "equalize" different engines.
#
################################################################################

SET autocommit = 0;
START TRANSACTION;
eval SET @conn_id = CONNECTION_ID(), @thread_id = 0;

--error 0, ER_LOCK_DEADLOCK, ER_LOCK_WAIT_TIMEOUT, ER_CHECKREAD
UPDATE t1 SET `int1` = `int1` - 4, 
              `id` = 4,
              `is_consistent` = 0,
              `connection_id` = @conn_id,
              `thread_id` = @thread_id
    WHERE `pk` = 4;

--source suite/engines/rr_trx/include/check_for_error_rollback.inc

--echo *** UPDATEing row with pk = 4 and `int1_key` +=4 if above statement succeeded (query log disabled)...

if (!$error)
{
    # This is conditional, so disable query log to avoid irrelevant diffs.
    --disable_query_log
    --error 0, ER_LOCK_DEADLOCK, ER_LOCK_WAIT_TIMEOUT, ER_CHECKREAD
    UPDATE t1 SET `int1_key` = `int1_key` + 4,
                  `is_consistent` = 1,
                  `connection_id` = @conn_id,
                  `thread_id` = @thread_id
        WHERE `pk` = 4;

    --source suite/engines/rr_trx/include/check_for_error_rollback.inc
    --enable_query_log
}

COMMIT;

Filemanager

Name Type Size Permission Actions
init_innodb.test File 110 B 0644
rr_c_count_not_zero.test File 1.02 KB 0644
rr_c_stats.test File 131 B 0644
rr_i_40-44.test File 5.54 KB 0644
rr_id_3.test File 995 B 0644
rr_id_900.test File 5.74 KB 0644
rr_insert_select_2.test File 2.11 KB 0644
rr_iud_rollback-multi-50.test File 3.02 KB 0644
rr_replace_7-8.test File 3.87 KB 0644
rr_s_select-uncommitted.test File 387 B 0644
rr_sc_select-limit-nolimit_4.test File 2.34 KB 0644
rr_sc_select-same_2.test File 1.93 KB 0644
rr_sc_sum_total.test File 968 B 0644
rr_u_10-19.test File 15.41 KB 0644
rr_u_10-19_nolimit.test File 15.03 KB 0644
rr_u_4.test File 1.36 KB 0644