MySQL  8.0.19
Source Code Documentation
dtuple_t Struct Reference

Structure for an SQL data tuple of fields (logical record) More...

#include <data0data.h>

Public Member Functions

 UT_LIST_NODE_T (dtuple_t) tuple_list
 Data tuples can be linked into a list using this field. More...
 
std::ostream & print (std::ostream &out) const
 Print the tuple to the output stream. More...
 
trx_id_t get_trx_id () const
 Read the trx id from the tuple (DB_TRX_ID) More...
 
void ignore_trailing_default (const dict_index_t *index)
 Ignore at most n trailing default fields if this is a tuple from instant index. More...
 
int compare (const rec_t *rec, const dict_index_t *index, const ulint *offsets, ulint *matched_fields) const
 Compare a data tuple to a physical record. More...
 
int compare (const rec_t *rec, const dict_index_t *index, const ulint *offsets) const
 Compare a data tuple to a physical record. More...
 
ulint get_n_ext () const
 Get number of externally stored fields. More...
 

Public Attributes

ulint info_bits
 info bits of an index record: the default is 0; this field is used if an index record is built from a data tuple More...
 
ulint n_fields
 Number of fields in dtuple. More...
 
ulint n_fields_cmp
 number of fields which should be used in comparison services of rem0cmp. More...
 
dfield_tfields
 Fields. More...
 
ulint n_v_fields
 Number of virtual fields. More...
 
dfield_tv_fields
 Fields on virtual column. More...
 
mem_heap_tm_heap
 memory heap where this tuple is allocated. More...
 
ulint magic_n
 Magic number, used in debug assertions. More...
 

Detailed Description

Structure for an SQL data tuple of fields (logical record)

Member Function Documentation

◆ compare() [1/2]

int dtuple_t::compare ( const rec_t rec,
const dict_index_t index,
const ulint *  offsets 
) const
inline

Compare a data tuple to a physical record.

Parameters
[in]recrecord
[in]indexindex
[in]offsetsrec_get_offsets(rec)
Returns
the comparison result of dtuple and rec
Return values
0if dtuple is equal to rec
negativeif dtuple is less than rec
positiveif dtuple is greater than rec

◆ compare() [2/2]

int dtuple_t::compare ( const rec_t rec,
const dict_index_t index,
const ulint *  offsets,
ulint *  matched_fields 
) const

Compare a data tuple to a physical record.

Parameters
[in]recrecord
[in]indexindex
[in]offsetsrec_get_offsets(rec)
[in,out]matched_fieldsnumber of completely matched fields
Returns
the comparison result of dtuple and rec
Return values
0if dtuple is equal to rec
negativeif dtuple is less than rec
positiveif dtuple is greater than rec

◆ get_n_ext()

ulint dtuple_t::get_n_ext ( ) const
inline

Get number of externally stored fields.

Return values
numberof externally stored fields.

◆ get_trx_id()

trx_id_t dtuple_t::get_trx_id ( ) const

Read the trx id from the tuple (DB_TRX_ID)

Returns
transaction id of the tuple.

◆ ignore_trailing_default()

void dtuple_t::ignore_trailing_default ( const dict_index_t index)

Ignore at most n trailing default fields if this is a tuple from instant index.

Parameters
[in]indexclustered index object for this tuple

◆ print()

std::ostream& dtuple_t::print ( std::ostream &  out) const
inline

Print the tuple to the output stream.

Parameters
[in,out]outStream to output to.
Returns
stream

◆ UT_LIST_NODE_T()

dtuple_t::UT_LIST_NODE_T ( dtuple_t  )

Data tuples can be linked into a list using this field.

Member Data Documentation

◆ fields

dfield_t* dtuple_t::fields

Fields.

◆ info_bits

ulint dtuple_t::info_bits

info bits of an index record: the default is 0; this field is used if an index record is built from a data tuple

◆ m_heap

mem_heap_t* dtuple_t::m_heap

memory heap where this tuple is allocated.

◆ magic_n

ulint dtuple_t::magic_n

Magic number, used in debug assertions.

◆ n_fields

ulint dtuple_t::n_fields

Number of fields in dtuple.

◆ n_fields_cmp

ulint dtuple_t::n_fields_cmp

number of fields which should be used in comparison services of rem0cmp.

*; the index search is performed by comparing only these fields, others are ignored; the default value in dtuple creation is the same value as n_fields

◆ n_v_fields

ulint dtuple_t::n_v_fields

Number of virtual fields.

◆ v_fields

dfield_t* dtuple_t::v_fields

Fields on virtual column.


The documentation for this struct was generated from the following files: