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

Function GetColOriginDefaultValue

pkg/table/column.go:553–555  ·  view source on GitHub ↗

GetColOriginDefaultValue gets default value of the column from original default value.

(ctx expression.BuildContext, col *model.ColumnInfo)

Source from the content-addressed store, hash-verified

551
552// GetColOriginDefaultValue gets default value of the column from original default value.
553func GetColOriginDefaultValue(ctx expression.BuildContext, col *model.ColumnInfo) (types.Datum, error) {
554 return getColDefaultValue(ctx, col, col.GetOriginDefaultValue(), nil)
555}
556
557// GetColOriginDefaultValueWithoutStrictSQLMode gets default value of the column from original default value with Strict SQL mode.
558func GetColOriginDefaultValueWithoutStrictSQLMode(ctx expression.BuildContext, col *model.ColumnInfo) (types.Datum, error) {

Callers 10

InsertColStats2KVFunction · 0.92
addRecordMethod · 0.92
GetColDefaultValueFunction · 0.92
fillRowChecksumFunction · 0.92
decodeOldRowValToChunkFunction · 0.92
getKeysNeedCheckOneRowFunction · 0.92
getOldRowFunction · 0.92
NewRowDecoderFunction · 0.92
CheckRecordAndIndexFunction · 0.92
TestGetDefaultValueFunction · 0.85

Calls 2

getColDefaultValueFunction · 0.85
GetOriginDefaultValueMethod · 0.80

Tested by 1

TestGetDefaultValueFunction · 0.68