Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/blastrain/vitess-sqlparser
/ functions
Functions
1,509 in github.com/blastrain/vitess-sqlparser
⨍
Functions
1,509
◇
Types & classes
344
↓ 8 callers
Method
FromFloat64
FromFloat64 creates a decimal from float64 value.
tidbparser/dependency/types/mydecimal.go:987
↓ 8 callers
Method
FromUint
FromUint sets the decimal value from uint64.
tidbparser/dependency/types/mydecimal.go:902
↓ 8 callers
Method
GetValue
GetValue gets the value of the datum of any kind.
tidbparser/dependency/types/datum.go:325
↓ 8 callers
Method
GoTime
GoTime converts MysqlTime to GoTime.
tidbparser/dependency/types/mytime.go:104
↓ 8 callers
Method
RoundFrac
RoundFrac rounds the fraction part of a time-type value according to `fsp`.
tidbparser/dependency/types/time.go:340
↓ 8 callers
Function
appendZero
(buf []byte, length int)
tidbparser/dependency/types/json/binary.go:472
↓ 8 callers
Function
calcDaynr
calcDaynr calculates days since 0000-00-00.
tidbparser/dependency/types/mytime.go:180
↓ 8 callers
Method
objectGetKey
(i int)
tidbparser/dependency/types/json/binary.go:180
↓ 8 callers
Function
splitDuration
(t gotime.Duration)
tidbparser/dependency/types/time.go:1062
↓ 7 callers
Function
CheckFsp
CheckFsp checks whether fsp is in valid range.
tidbparser/dependency/types/fsp.go:37
↓ 7 callers
Function
CompareInt64
CompareInt64 returns an integer comparing the int64 x to y.
tidbparser/dependency/types/compare.go:17
↓ 7 callers
Function
CompareUint64
CompareUint64 returns an integer comparing the uint64 x to y.
tidbparser/dependency/types/compare.go:28
↓ 7 callers
Method
Consume
Consume is used to consume a memory usage. "bytes" can be a negative value, which means this is a memory release operation.
tidbparser/dependency/util/memory/tracker.go:110
↓ 7 callers
Function
CreateBinary
CreateBinary creates a BinaryJSON from interface.
tidbparser/dependency/types/json/binary.go:411
↓ 7 callers
Method
HandleTruncate
HandleTruncate ignores or returns the error based on the StatementContext state.
tidbparser/dependency/sessionctx/stmtctx/stmtctx.go:141
↓ 7 callers
Method
IsEmpty
IsEmpty returns true if the name is empty.
sqlparser/ast.go:2483
↓ 7 callers
Function
NewTableIdent
NewTableIdent creates a new TableIdent.
sqlparser/ast.go:2547
↓ 7 callers
Function
ParseTime
ParseTime parses a formatted string with type tp and specific fsp. Type is TypeDatetime, TypeTimestamp and TypeDate. Fsp is in range [0, 6]. MySQL sup
tidbparser/dependency/types/time.go:1197
↓ 7 callers
Method
SetMysqlDecimal
SetMysqlDecimal sets Decimal value
tidbparser/dependency/types/datum.go:247
↓ 7 callers
Method
SetUint64
SetUint64 sets uint64 value.
tidbparser/dependency/types/datum.go:142
↓ 7 callers
Method
Write
Write is equivalent to bytes.Buffer.Write.
bytes2/buffer.go:35
↓ 7 callers
Function
add
add adds a and b and carry, returns the sum and new carry.
tidbparser/dependency/types/mydecimal.go:77
↓ 7 callers
Method
extractTo
(buf []BinaryJSON, pathExpr PathExpression)
tidbparser/dependency/types/json/binary_functions.go:166
↓ 7 callers
Method
finishAppendFixed
()
tidbparser/dependency/util/chunk/chunk.go:372
↓ 7 callers
Function
getTime
(sc *stmtctx.StatementContext, num int64, tp byte)
tidbparser/dependency/types/time.go:1082
↓ 7 callers
Function
isLetter
(ch uint16)
sqlparser/token.go:699
↓ 7 callers
Method
objectGetVal
(i int)
tidbparser/dependency/types/json/binary.go:186
↓ 7 callers
Method
setLastSelectFieldText
The select statement is not at the end of the whole statement, if the last field text was set from its offset to the end of the src string, update the
tidbparser/parser/yy_parser.go:144
↓ 6 callers
Method
ConvertToDuration
ConvertToDuration converts mysql datetime, timestamp and date to mysql time type. e.g, 2012-12-12T10:10:10 -> 10:10:10 2012-12-12 -> 0
tidbparser/dependency/types/time.go:281
↓ 6 callers
Function
IsTypeBlob
IsTypeBlob returns a boolean indicating whether the tp is a blob type.
tidbparser/dependency/types/etc.go:32
↓ 6 callers
Function
IsTypeChar
IsTypeChar returns a boolean indicating whether the tp is the char type like a string type or a varchar type.
tidbparser/dependency/types/etc.go:43
↓ 6 callers
Method
Lowered
Lowered returns a lower-cased column name. This function should generally be used only for optimizing comparisons.
sqlparser/ast.go:2504
↓ 6 callers
Function
RoundFloat
RoundFloat rounds float val to the nearest integer value with float64 format, like MySQL Round function. RoundFloat uses default rounding mode, see ht
tidbparser/dependency/types/helper.go:28
↓ 6 callers
Function
StrToFloat
StrToFloat converts a string to a float64 at the best-effort.
tidbparser/dependency/types/convert.go:303
↓ 6 callers
Function
adjustYear
adjustYear adjusts year according to y. See https://dev.mysql.com/doc/refman/5.7/en/two-digit-years.html
tidbparser/dependency/types/time.go:730
↓ 6 callers
Method
check
check whether t matches valid Time format. If allowZeroInDate is false, it returns ErrZeroDate when month or day is zero. FIXME: See https://dev.mysql
tidbparser/dependency/types/time.go:445
↓ 6 callers
Function
compareTime
(a, b MysqlTime)
tidbparser/dependency/types/time.go:300
↓ 6 callers
Function
fixWordCntError
fixWordCntError limits word count in wordBufLen, and returns overflow or truncate error.
tidbparser/dependency/types/mydecimal.go:118
↓ 6 callers
Function
isDigit
(ch uint16)
sqlparser/token.go:715
↓ 6 callers
Method
scan
()
tidbparser/parser/lexer.go:50
↓ 6 callers
Method
scanMantissa
(base int, buffer *bytes2.Buffer)
sqlparser/token.go:563
↓ 6 callers
Function
yyTokname
(c int)
sqlparser/sql.go:1214
↓ 5 callers
Method
Clone
Clone clones FKInfo.
tidbparser/dependency/model/model.go:308
↓ 5 callers
Function
ConvertFloatToInt
ConvertFloatToInt converts a float64 value to a int value.
tidbparser/dependency/types/convert.go:71
↓ 5 callers
Function
ConvertFloatToUint
ConvertFloatToUint converts a float value to an uint value.
tidbparser/dependency/types/convert.go:127
↓ 5 callers
Function
ConvertIntToInt
ConvertIntToInt converts an int value to another int value of different precision.
tidbparser/dependency/types/convert.go:87
↓ 5 callers
Method
Error
(s string)
sqlparser/sql.go:1190
↓ 5 callers
Method
GetBytes
GetBytes gets bytes value.
tidbparser/dependency/types/datum.go:186
↓ 5 callers
Method
GetFloat32
GetFloat32 gets float32 value.
tidbparser/dependency/types/datum.go:159
↓ 5 callers
Method
GetMyDecimal
GetMyDecimal returns the MyDecimal value with the colIdx.
tidbparser/dependency/types/row.go:54
↓ 5 callers
Method
MemoryUsage
MemoryUsage returns the total memory usage of a Chunk in B. We ignore the size of column.length and column.nullCount since they have little effect of
tidbparser/dependency/util/chunk/chunk.go:63
↓ 5 callers
Function
MulUint64
MulUint64 multiplies uint64 a and b and returns uint64 if no overflow error.
tidbparser/dependency/types/overflow.go:88
↓ 5 callers
Method
NewString
NewString copies a byte slice into the arena and returns it as a string. If the arena is full, it returns a traditional go string.
hack/hack.go:45
↓ 5 callers
Function
NewWhere
NewWhere creates a WHERE or HAVING clause out of a Expr. If the expression is nil, it returns nil.
sqlparser/ast.go:1331
↓ 5 callers
Method
NumChunks
NumChunks returns the number of chunks in the List.
tidbparser/dependency/util/chunk/list.go:63
↓ 5 callers
Function
Parse
Instructions for creating new types: If a type needs to satisfy an interface, declare that function along with that interface. This will help users id
sqlparser/ast.go:45
↓ 5 callers
Function
ParseDuration
ParseDuration parses the time form a formatted string with a fractional seconds part, returns the duration type Time value. See http://dev.mysql.com/d
tidbparser/dependency/types/time.go:930
↓ 5 callers
Function
ParseTimeFromNum
ParseTimeFromNum parses a formatted int64, returns the value which type is tp.
tidbparser/dependency/types/time.go:1242
↓ 5 callers
Method
PrecisionAndFrac
PrecisionAndFrac returns the internal precision and frac number.
tidbparser/dependency/types/mydecimal.go:1190
↓ 5 callers
Method
Reset
Reset resets the List.
tidbparser/dependency/util/chunk/list.go:128
↓ 5 callers
Method
SetBytes
SetBytes sets bytes value to datum.
tidbparser/dependency/types/datum.go:191
↓ 5 callers
Method
SetMysqlTime
SetMysqlTime sets types.Time value
tidbparser/dependency/types/datum.go:308
↓ 5 callers
Method
SetValue
SetValue sets any kind of value.
tidbparser/dependency/types/datum.go:359
↓ 5 callers
Method
SpaceLeft
SpaceLeft returns the amount of space left in the arena.
hack/hack.go:58
↓ 5 callers
Method
ToViewName
ToViewName returns a TableName acceptable for use as a VIEW. VIEW names are always lowercase, so ToViewName lowercasese the name. Databases are case-s
sqlparser/ast.go:1212
↓ 5 callers
Method
addFixedLenColumn
addFixedLenColumn adds a fixed length column with elemLen and initial data capacity.
tidbparser/dependency/util/chunk/chunk.go:72
↓ 5 callers
Method
appendNullBitmap
(on bool)
tidbparser/dependency/util/chunk/chunk.go:349
↓ 5 callers
Function
buildBinaryArray
(elems []BinaryJSON)
tidbparser/dependency/types/json/binary_functions.go:226
↓ 5 callers
Function
checkErr
(t *testing.T, err error)
sqlparser/sqlparser_test.go:8
↓ 5 callers
Method
isNull
(rowIdx int)
tidbparser/dependency/util/chunk/chunk.go:344
↓ 5 callers
Function
makeMutRowUint64Column
(val uint64)
tidbparser/dependency/util/chunk/mutrow.go:189
↓ 5 callers
Function
myMax
(a, b int)
tidbparser/dependency/types/helper.go:103
↓ 5 callers
Function
myMaxInt8
(a, b int8)
tidbparser/dependency/types/helper.go:110
↓ 5 callers
Function
newMutRowFixedLenColumn
(elemSize int)
tidbparser/dependency/util/chunk/mutrow.go:165
↓ 5 callers
Method
readByte
()
tidbparser/parser/lexer.go:728
↓ 5 callers
Method
rebuild
rebuild merges the old and the modified JSON into a new BinaryJSON
tidbparser/dependency/types/json/binary_functions.go:461
↓ 5 callers
Function
setMutRowBytes
(col *column, bin []byte)
tidbparser/dependency/util/chunk/mutrow.go:308
↓ 5 callers
Method
startOffset
(v *yySymType)
tidbparser/parser/yy_parser.go:151
↓ 4 callers
Method
AppendBytes
AppendBytes appends a bytes value to the chunk.
tidbparser/dependency/util/chunk/chunk.go:255
↓ 4 callers
Method
AppendWarning
AppendWarning appends a warning.
tidbparser/dependency/sessionctx/stmtctx/stmtctx.go:117
↓ 4 callers
Method
BytesConsumed
BytesConsumed returns the consumed memory usage value in bytes.
tidbparser/dependency/util/memory/tracker.go:126
↓ 4 callers
Function
ConvertIntToUint
ConvertIntToUint converts an int value to an uint value.
tidbparser/dependency/types/convert.go:109
↓ 4 callers
Function
DecodeInt
DecodeInt decodes value encoded by EncodeInt before. It returns the leftover un-decoded slice, decoded value if no error.
tidbparser/dependency/util/codec/number.go:55
↓ 4 callers
Method
EncodeSQL
(buf *bytes.Buffer)
sqlparser/encodable.go:30
↓ 4 callers
Function
EncodeUint
EncodeUint appends the encoded value to slice b and returns the appended slice. EncodeUint guarantees that the encoded value is in ascending order for
tidbparser/dependency/util/codec/number.go:81
↓ 4 callers
Function
FromGoTime
FromGoTime translates time.Time to mysql time internal representation.
tidbparser/dependency/types/time.go:140
↓ 4 callers
Method
GetChunk
GetChunk gets the Chunk by ChkIdx.
tidbparser/dependency/util/chunk/list.go:68
↓ 4 callers
Function
GetDefaultFieldLengthAndDecimalForCast
GetDefaultFieldLengthAndDecimalForCast returns the default display length (flen) and decimal length for casted column when flen or decimal is not spec
tidbparser/dependency/mysql/util.go:87
↓ 4 callers
Method
GetDuration
GetDuration returns the Duration value with the colIdx.
tidbparser/dependency/types/row.go:45
↓ 4 callers
Method
GetJSON
GetJSON returns the JSON value with the colIdx.
tidbparser/dependency/types/row.go:57
↓ 4 callers
Method
GetTime
GetTime returns the Time value with the colIdx.
tidbparser/dependency/types/row.go:42
↓ 4 callers
Method
GetValue
GetValue gets value of the expression.
tidbparser/ast/ast.go:70
↓ 4 callers
Method
Len
Len implements the Iterator interface.
tidbparser/dependency/util/chunk/iterator.go:97
↓ 4 callers
Method
Len
Len implements the Iterator interface.
tidbparser/dependency/util/chunk/iterator.go:277
↓ 4 callers
Method
Len
Len is equivalent to bytes.Buffer.Len.
bytes2/buffer.go:63
↓ 4 callers
Method
MicroSecond
MicroSecond returns current microsecond. e.g, hour("11:11:11.11") -> 110000
tidbparser/dependency/types/time.go:922
↓ 4 callers
Method
NumCols
NumCols returns the number of columns in the chunk.
tidbparser/dependency/util/chunk/chunk.go:140
↓ 4 callers
Method
Parse
(yyLexer)
sqlparser/sql.go:1194
↓ 4 callers
Method
SetBinaryLiteral
SetBinaryLiteral sets Bit value
tidbparser/dependency/types/datum.go:230
↓ 4 callers
Method
SetFloat32
SetFloat32 sets float32 value.
tidbparser/dependency/types/datum.go:164
← previous
next →
101–200 of 1,509, ranked by callers