5f340b88c9
parser: format error message during parsing when meet a big value. ( #28791 )
2021-11-18 00:51:47 +08:00
b3bae059ee
parser: add Str2Type method. ( #29857 )
2021-11-17 16:27:47 +08:00
11b61738f3
parser: migrate test-infra to testify ( #29191 )
2021-10-28 12:30:49 +08:00
94e30df8e2
parser: fix compiling, add unit tests ( #28700 )
2021-10-11 23:15:25 +08:00
ad06cfff94
[parser] support cast as year syntax ( #1293 )
2021-10-09 14:53:23 +08:00
67b2a63ac9
[parser] Add EnumSetAsIntFlag flag to control enum behavior. ( #1165 )
...
* add enumset as int flag
* update evaltype
* add has function
* Update mysql/type.go
Co-authored-by: tangenta <tangenta@126.com >
Co-authored-by: tangenta <tangenta@126.com >
2021-10-09 14:53:23 +08:00
b777f86c22
[parser] done ( #1108 )
...
Signed-off-by: wjhuang2016 <huangwenjun1997@gmail.com >
2021-10-09 14:53:23 +08:00
e3daabacc0
[parser] *: redact arguments for Error ( #1051 )
2021-10-09 14:53:23 +08:00
0e71182447
[parser] types: allows more types to be equal ( #1041 )
...
Signed-off-by: wjhuang2016 <huangwenjun1997@gmail.com >
2021-10-09 14:53:23 +08:00
a329df515d
[parser] fix tiny bug about cast function ( #995 )
2021-10-09 14:53:23 +08:00
8dc1467a7f
[parser] correct calculation of field lengths for Enum and Set types ( #954 )
...
* fix invalid enum flen
* fix invalid set flen
* address comments
2021-10-09 14:53:23 +08:00
a1997e6b2a
[parser] add config variable to control max display length ( #949 )
2021-10-09 14:53:23 +08:00
63da8aaba0
[parser] fix: remove TypeDecimal ( #944 )
...
Signed-off-by: Wang Ruichao <wangruichao2014@xiaochuankeji.cn >
2021-10-09 14:53:23 +08:00
2a676ef0da
[parser] types: fix restore cast as binary ( #922 )
...
Signed-off-by: wjhuang2016 <huangwenjun1997@gmail.com >
2021-10-09 14:53:23 +08:00
5757f0b3c8
[parser] types: Update FieldType.Equal safety. ( #841 )
...
* Fix float flen free bug.
* Add unit test
2021-10-09 14:53:23 +08:00
cda62de3ce
[parser] types: Don't check Flen when Tp is double or float in FieldType.Equal. ( #832 )
...
* float flen free.
* Fix bug.
2021-10-09 14:53:23 +08:00
00ada7f542
[parser] terror: replace sirupsen/logrus by pingcap/log ( #693 )
...
* terror: replace sirupsen/logrus by pingcap/log
also fixed test failure on Windows
* circle.yml: restrict test parallelism in integration tests
also, stop verifying parser.go and code format in the integration tests...
those steps are redundant.
* codecov: add codecov.yml, based on pingcap/tidb#9618
Co-authored-by: tiancaiamao <tiancaiamao@gmail.com >
2021-10-09 14:53:23 +08:00
b9268c63bc
[parser] remove dependency on TiDB ( #679 )
2021-10-09 14:53:23 +08:00
989870f109
[parser] *: remove testleak ( #676 )
2021-10-09 14:53:23 +08:00
94eb38bc74
[parser] clean up error code and message for parser ( #618 )
2021-10-09 14:53:23 +08:00
4eea70ebce
[parser] Fix AST.Restore() restore char(1) to char(1,0) ( #421 )
...
* fix4496
* fix4496
2021-10-09 14:53:23 +08:00
a580fe29ee
[parser] parser: support cast as float ( #416 )
...
* parser: support_cast_as_float
* fix
2021-10-09 14:53:23 +08:00
f100bfdd65
[parser] parser: support cast as double ( #399 )
2021-10-09 14:53:23 +08:00
c3f5479d6b
[parser] Fix handling of FLOAT(p), FLOAT(m,d) and DECIMAL(m,0) types esp. w.r.t. Restore() ( #311 )
...
* parser: fix handling of FLOAT(p) and FLOAT(m,d) types
* FLOAT(50,4) should not automatically become a DOUBLE, it is just a FLOAT
shown with 50 digits.
* FLOAT(0) and FLOAT(24) are the alias of the same type FLOAT. There is no
need to record the Flen.
* types: fix Restore of DECIMAL(m,0) types
* tests: add test cases
2021-10-09 14:53:23 +08:00
568898c8d7
[parser] type/compatibility: fix show create table output of generated column ( #235 )
2021-10-09 14:53:23 +08:00
4eae120d0c
[parser] types: port 'HasCharset' function from MySQL ( #270 )
2021-10-09 14:53:23 +08:00
f9f7fa9a16
[parser] types: Fix description for year type ( #200 )
2021-10-09 14:53:23 +08:00
84f9b45d16
[parser] parser: finish the restore function of all ast node ( #206 )
...
* add test
* restore bindings
* restore bindings
* restore ddl
* charset info
* charset info
* fix fmt
* use keyword write charset
* gomod
* gosum
2021-10-09 14:53:23 +08:00
7abc99d6e3
[parser] parser: implement Restore for CreateTableStmt ( #170 )
2021-10-09 14:53:23 +08:00
d057e9ebaf
[parser] parser: implement Restore for ColumnOption, FieldType and ColumnDef ( #160 )
2021-10-09 14:53:23 +08:00
6d3f99487a
[parser] parser: implement Restore for FuncCallExpr and AggregateFuncExpr ( #102 )
2021-10-09 14:53:23 +08:00
3fb7739efa
[parser] refactor the PR #8619 by introducing the FieldType.Clone() member function ( #77 )
2021-10-09 14:53:23 +08:00
6f2c7111c4
[parser] *: change default charset from utf8 to utf8mb4 ( #13 )
2021-10-09 14:53:23 +08:00
c270f55405
[parser] *: move github.com/pingcap/tidb/parser here ( #1 )
2021-10-09 14:53:23 +08:00
89dda9d9a8
*: move parser to a separate repository ( #8036 )
2018-10-25 11:12:10 +08:00
bd08b0bc70
*: make parser package dependency as small as possible ( #7989 )
2018-10-24 13:19:10 +08:00