MCPcopy
hub / github.com/pingcap/tidb / EncodeValue

Function EncodeValue

pkg/util/codec/codec.go:309–311  ·  view source on GitHub ↗

EncodeValue appends the encoded values to byte slice b, returning the appended slice. It does not guarantee the order for comparison.

(loc *time.Location, b []byte, v ...types.Datum)

Source from the content-addressed store, hash-verified

307// EncodeValue appends the encoded values to byte slice b, returning the appended
308// slice. It does not guarantee the order for comparison.
309func EncodeValue(loc *time.Location, b []byte, v ...types.Datum) ([]byte, error) {
310 return encode(loc, b, v, false)
311}
312
313func encodeHashChunkRowIdx(typeCtx types.Context, row chunk.Row, tp *types.FieldType, idx int) (flag byte, b []byte, err error) {
314 if row.IsNull(idx) {

Callers 15

GroupRangesByColsFunction · 0.92
InsertValueMethod · 0.92
InsertRowValueMethod · 0.92
insertMethod · 0.92
prepareCMSAndTopNFunction · 0.92
TestPartialNextFunction · 0.92
useDefaultEncodingFunction · 0.92
toTiPBChunkMethod · 0.92
getGroupKeyMethod · 0.92
countFinishMethod · 0.92
chunkToOldChunkMethod · 0.92
getGroupKeyMethod · 0.92

Calls 1

encodeFunction · 0.85

Tested by 14

insertMethod · 0.74
prepareCMSAndTopNFunction · 0.74
TestPartialNextFunction · 0.74
mockChunkFunction · 0.74
TestTempIndexValueCodecFunction · 0.74
TestHashGroupKeyFunction · 0.74
datumExprFunction · 0.74
composeEncodedDataFunction · 0.56
TestCodecKeyFunction · 0.56
TestDecimalFunction · 0.56
TestCutFunction · 0.56
TestSetRawValuesFunction · 0.56