00001
00002
00003
00004
00005
00006
00007
00008
00009
00010
00011
00012
00013
00014
00015
00016
00017
00018
00019
00026 #pragma once
00027 #ifndef row0row_h
00028 #define row0row_h
00029
00030 #include "univ.i"
00031 #include "data0data.h"
00032 #include "dict0types.h"
00033 #include "trx0types.h"
00034 #include "que0types.h"
00035 #include "mtr0mtr.h"
00036 #include "rem0types.h"
00037 #include "read0types.h"
00038 #include "row0types.h"
00039 #include "btr0types.h"
00040
00041
00045 UNIV_INTERN
00046 ulint
00047 row_get_trx_id_offset(
00048
00049 const rec_t* rec,
00050 dict_index_t* index,
00051 const ulint* offsets);
00052
00055 UNIV_INLINE
00056 trx_id_t
00057 row_get_rec_trx_id(
00058
00059 const rec_t* rec,
00060 dict_index_t* index,
00061 const ulint* offsets);
00062
00065 UNIV_INLINE
00066 roll_ptr_t
00067 row_get_rec_roll_ptr(
00068
00069 const rec_t* rec,
00070 dict_index_t* index,
00071 const ulint* offsets);
00072
00078 UNIV_INTERN
00079 dtuple_t*
00080 row_build_index_entry(
00081
00082 const dtuple_t* row,
00084 row_ext_t* ext,
00086 dict_index_t* index,
00087 mem_heap_t* heap);
00089
00093 UNIV_INTERN
00094 dtuple_t*
00095 row_build(
00096
00097 ulint type,
00104 const dict_index_t* index,
00105 const rec_t* rec,
00114 const ulint* offsets,
00117 const dict_table_t* col_table,
00126 row_ext_t** ext,
00129 mem_heap_t* heap);
00131
00135 UNIV_INTERN
00136 dtuple_t*
00137 row_rec_to_index_entry_low(
00138
00139 const rec_t* rec,
00140 const dict_index_t* index,
00141 const ulint* offsets,
00142 ulint* n_ext,
00144 mem_heap_t* heap);
00146
00150 UNIV_INTERN
00151 dtuple_t*
00152 row_rec_to_index_entry(
00153
00154 ulint type,
00160 const rec_t* rec,
00169 const dict_index_t* index,
00170 ulint* offsets,
00171 ulint* n_ext,
00173 mem_heap_t* heap);
00175
00179 UNIV_INTERN
00180 dtuple_t*
00181 row_build_row_ref(
00182
00183 ulint type,
00187 dict_index_t* index,
00188 const rec_t* rec,
00195 mem_heap_t* heap);
00197
00200 UNIV_INTERN
00201 void
00202 row_build_row_ref_in_tuple(
00203
00204 dtuple_t* ref,
00206 const rec_t* rec,
00214 const dict_index_t* index,
00215 ulint* offsets,
00217 trx_t* trx);
00218
00221 UNIV_INLINE
00222 void
00223 row_build_row_ref_fast(
00224
00225 dtuple_t* ref,
00227 const ulint* map,
00230 const rec_t* rec,
00233 const ulint* offsets);
00234
00238 UNIV_INTERN
00239 ibool
00240 row_search_on_row_ref(
00241
00242 btr_pcur_t* pcur,
00244 ulint mode,
00245 const dict_table_t* table,
00246 const dtuple_t* ref,
00247 mtr_t* mtr);
00248
00252 UNIV_INTERN
00253 rec_t*
00254 row_get_clust_rec(
00255
00256 ulint mode,
00257 const rec_t* rec,
00258 dict_index_t* index,
00259 dict_index_t** clust_index,
00260 mtr_t* mtr);
00263 enum row_search_result {
00264 ROW_FOUND = 0,
00265 ROW_NOT_FOUND,
00266 ROW_BUFFERED,
00271 ROW_NOT_DELETED_REF
00273 };
00274
00275
00278 UNIV_INTERN
00279 enum row_search_result
00280 row_search_index_entry(
00281
00282 dict_index_t* index,
00283 const dtuple_t* entry,
00284 ulint mode,
00285 btr_pcur_t* pcur,
00287 mtr_t* mtr);
00290 #define ROW_COPY_DATA 1
00291 #define ROW_COPY_POINTERS 2
00292
00293
00294
00295
00296
00297
00298
00299
00300
00301
00309 UNIV_INTERN
00310 ulint
00311 row_raw_format(
00312
00313 const char* data,
00314 ulint data_len,
00316 const dict_field_t* dict_field,
00317 char* buf,
00318 ulint buf_size);
00321 #ifndef UNIV_NONINL
00322 #include "row0row.ic"
00323 #endif
00324
00325 #endif