#include "univ.i"
#include "mtr0mtr.h"
#include "trx0sys.h"
#include "btr0types.h"
#include "btr0pcur.h"
#include "dict0types.h"
#include "trx0types.h"
#include "que0types.h"
#include "row0types.h"
Go to the source code of this file.
Classes | |
struct | undo_node_struct |
Enumerations | |
enum | undo_exec { UNDO_NODE_FETCH_NEXT = 1, UNDO_NODE_PREV_VERS, UNDO_NODE_INSERT, UNDO_NODE_MODIFY } |
Functions | |
UNIV_INTERN undo_node_t * | row_undo_node_create (trx_t *trx, que_thr_t *parent, mem_heap_t *heap) |
UNIV_INTERN ibool | row_undo_search_clust_to_pcur (undo_node_t *node) |
UNIV_INTERN que_thr_t * | row_undo_step (que_thr_t *thr) |
enum undo_exec |
Execution state of an undo node
Definition at line 88 of file row0undo.h.
UNIV_INTERN undo_node_t* row_undo_node_create | ( | trx_t * | trx, |
que_thr_t * | parent, | ||
mem_heap_t * | heap | ||
) |
Creates a row undo node to a query graph.
Creates a row undo node to a query graph.
trx | in: transaction |
parent | in: parent node, i.e., a thr node |
heap | in: memory heap where created |
Definition at line 128 of file row0undo.cc.
References btr_pcur_init(), undo_node_struct::common, undo_node_struct::heap, mem_heap_alloc(), mem_heap_create, que_common_struct::parent, undo_node_struct::pcur, row_undo_node_create(), undo_node_struct::state, undo_node_struct::trx, que_common_struct::type, UNDO_NODE_FETCH_NEXT, and ut_ad.
Referenced by row_undo_node_create(), and trx_roll_graph_build().
UNIV_INTERN ibool row_undo_search_clust_to_pcur | ( | undo_node_t * | node | ) |
Looks for the clustered index record when node has the row reference. The pcur in node is used in the search. If found, stores the row to node, and stores the position of pcur, and detaches it. The pcur must be closed by the caller in any case.
Looks for the clustered index record when node has the row reference. The pcur in node is used in the search. If found, stores the row to node, and stores the position of pcur, and detaches it. The pcur must be closed by the caller in any case.
node | in: row undo node |
Definition at line 162 of file row0undo.cc.
References BTR_MODIFY_LEAF, btr_pcur_commit_specify_mtr(), btr_pcur_get_rec(), dict_table_get_format(), DICT_TF_FORMAT_ZIP, dtuple_copy(), undo_node_struct::ext, undo_node_struct::heap, mem_heap_free, mtr_start(), undo_node_struct::pcur, undo_node_struct::ref, undo_node_struct::roll_ptr, undo_node_struct::row, row_build(), row_get_rec_roll_ptr(), row_search_on_row_ref(), row_undo_search_clust_to_pcur(), row_upd_replace(), undo_node_struct::table, undo_node_struct::undo_ext, undo_node_struct::undo_row, and undo_node_struct::update.
Referenced by row_undo_ins(), row_undo_mod(), and row_undo_search_clust_to_pcur().
Undoes a row operation in a table. This is a high-level function used in SQL execution graphs.
Undoes a row operation in a table. This is a high-level function used in SQL execution graphs.
thr | in: query thread |
Definition at line 349 of file row0undo.cc.
References trx_struct::error_state, que_node_get_type(), row_undo_step(), que_thr_struct::run_node, thr_get_trx(), ut_ad, and ut_error.
Referenced by row_undo_step().