Commit Graph

862 Commits

Author SHA1 Message Date
e96321b3f1 ranger: simple improvement for range calc for pk. (#4767) 2017-10-24 20:21:23 +08:00
0306bb0070 tidb: support a plan cache for prepared statements (#3956)
* tidb: support a plan cache for prepared statements
2017-10-24 00:55:51 -05:00
ed7f68ca9b *: Add Row interface (#4859) 2017-10-23 11:36:28 +08:00
4867bcfa3e expression: fix a bug occured in select sum(float col)*0.1 (#4854)
* expression: fix a bug occured in select sum(1.2e2)*0.1
2017-10-20 20:42:28 -05:00
3d6ec2a362 expression: correct the signature building of Values (#4814) 2017-10-18 21:23:07 -05:00
a34964a36a *: improve the column info for client (#4770)
Add table/database info in the response message.
2017-10-15 08:27:13 -05:00
64bc8cb6cb expression: remove "self" field in "baseBuiltinFunc" completely (#4766)
* expression: remove "self" field in "baseBuiltinFunc" completely

* address comment
2017-10-13 04:55:25 -05:00
60626912a7 expression, plan: remove "foldable" from "baseBuiltinFunc" (#4759) 2017-10-12 04:03:54 -05:00
e488bcc23d expression: some builtin functions can be folded (#4756)
* expression: unix_timestamp, utc_timestamp can be folded

* add mores exprs

* add non-cacheable functions
2017-10-12 01:18:26 -05:00
51a6e6fc48 *: fix ineffectual assignments #4713 (#4746) 2017-10-11 21:26:03 -05:00
83ace4f748 expression: return NULL when error is not nil (#4749) 2017-10-11 03:38:03 -05:00
7d2804e43c *: check sc.IgnoreZeroInDate when parsing string or number to date/datetime/timestamp (#4732) 2017-10-10 23:38:53 -05:00
3e1d036336 *: log the caller of "terror.Log()" (#4729) 2017-10-10 11:26:43 +08:00
e11c4fbaad expression, plan: improve fold constant (#4721)
* improve fold constant

* remove useless code

* remove useless argument

* address comment
2017-10-09 17:43:13 +08:00
9c2ea17722 *: enforce errcheck in Makefile (#4724)
checks all errors and enable errcheck in Makefile

Fixes https://github.com/pingcap/tidb/issues/4668
2017-10-09 17:16:10 +08:00
17b3a377f0 expression: use ParseTimeFormNum instead of ParseTime (#4706) 2017-10-09 12:10:24 +08:00
ca05619cdf expression: enforce error check (#4716) 2017-10-08 22:29:07 -05:00
1c99d41ca2 expression: Quit builtin function SLEEP when KILLed. (#4708) 2017-10-08 21:12:36 -05:00
3f4bdf6150 expression: rewrite unit test for Minus and Plus (#4691)
* expression: rewrite unit test for Minus and Plus

* move code
2017-09-30 11:47:26 +08:00
b4ad894b0a expression, plan: do come code clean and make golint happy (#4681) 2017-09-29 10:35:47 +08:00
56ed7f129d expression: change like function's behavior. (#4683) 2017-09-29 10:27:23 +08:00
07e8911628 *: reduce growslice (#4680) 2017-09-28 18:00:32 +08:00
459c4691b5 expression: remove useless code (#4672) 2017-09-28 16:03:04 +08:00
2d0041e134 *: add combination sql modes support(#4631) (#4633)
Fix #4631
2017-09-28 10:01:48 +08:00
1c4143e9e4 expression, types: remove the useage of "evalExprToXXX" functions (#4666) 2017-09-27 23:42:00 +08:00
a6756a4eee *: make insert with calculated value behave the same as MySQL. (#4603) 2017-09-27 19:59:31 +08:00
baee1bb864 expression, types, plan: remove the usage of "TypeClass" completely (#4654) 2017-09-27 12:39:44 +08:00
7943d0e843 expression, types: remove the usage of "TypeClass" in "builtin_compare.go" (#4649) 2017-09-26 23:33:56 +08:00
f89db5b6ec expression, types: export "evalTp" to "EvalType" and move it to package "types" (#4626)
* expression, types: export "evalTp" to "EvalType" and move it to package "types"

* add source file

* change "ETJSON" to "ETJson"
2017-09-26 11:25:27 +08:00
6f84392d40 *: optimize SortExec (#4622)
* *: change key of orderByRow from "key []types.Datum" to "key []*types.Datum"

* address comment
2017-09-25 19:50:26 +08:00
45bdd69cde *: support signature push down. (#4495) 2017-09-25 18:58:42 +08:00
e599ceec2b types: fix 'select cast(12.1 as decimal(3,4))' core. (#4612) 2017-09-24 21:17:17 +08:00
d2d14d8c48 *: 1. remove expression/typeinfer.go entirely (#4611)
2. remove the validator of sql like 'insert into t set a = 1, b = a'
2017-09-22 20:27:03 +08:00
25b5a2ce18 *: Refactor aggregation (#4605)
Aggregation results were stored in aggregation functions, so one map is created for each function to store different groups’ results, which requires much memory.
The aggregation functions are refactored and are now stateless, and the maps are kept in executor (executor.HashAggExec and mocktikv.aggregateExec) so that only one map is needed to store all the functions’ results, which reduced the memory usage.
2017-09-22 19:41:01 +08:00
a60bbd9560 expression: refactor "helper.go" (#4593) 2017-09-22 18:54:04 +08:00
069cc8b222 expression: open new expression framework by default (#4595) 2017-09-22 15:29:42 +08:00
bd01434de0 expression: remove the usage of "TypeClass" in "builtin_arithmetic.go" (#4575) 2017-09-22 13:52:10 +08:00
3c02f6bcdb expression, plan: remove typeinfer.go since we infer all types in expression rewrite phrase (#4536) 2017-09-22 13:22:46 +08:00
376a7ddbdd util/types,expression: fix parseDatetime for 11111111111 and 20170118.999 (#4273) 2017-09-21 14:55:05 +08:00
a12306c45e expression: remove the usage of "TypeClass" in "expression.go" (#4571) 2017-09-21 12:43:37 +08:00
a8b09d2761 expression: reorganize error messages for non-existent functions (#4582) 2017-09-21 12:14:50 +08:00
d089deb1b0 expression: remove the usage of "TypeClass" in "builtin_string.go" (#4573) 2017-09-21 10:30:11 +08:00
c899e5bb16 expression: rewrite builtin function: MOD (#4407) 2017-09-21 09:48:51 +08:00
dba31ef24a expression: remove the usage of "TypeClass" in "builtin_math.go" (#4568) 2017-09-21 09:33:16 +08:00
c9e17e8317 plan: wrap CAST on generation expressions. (#4501)
* plan: wrap CAST on generation expressions.
2017-09-20 19:49:34 +08:00
71c7470911 expression: remove the usage of "TypeClass" in "builtin_cast.go" (#4570)
* expression: remove the usage of "TypeClass" in "builtin_cast.go"
2017-09-20 19:43:38 +08:00
c92b124aa9 *: make test leak great again (#4543) 2017-09-20 17:07:32 +08:00
2439f173dc expression: move "Constant" to a standalone source file (#4583) 2017-09-20 15:02:30 +08:00
a2393245dd parser, ast, expression: support TIME/TIMESTAMP literal (#4368) 2017-09-19 16:37:29 +08:00
2762c44161 *: move aggregate functions to an individual package "aggregation" (#4549) 2017-09-18 15:07:35 +08:00