Commit Graph

60 Commits

Author SHA1 Message Date
72d4504f45 planner: fix explain-hint panic for joins generated by subquery (#20675) 2020-12-03 15:18:37 +08:00
2c66371d8b planner, sessionctx : Add 'last_plan_from_binding' to help know whether sql's plan is matched with the hints in the binding (#18017) 2020-11-20 20:43:23 +08:00
f72cec77b6 *: support SQL bind for Update / Delete / Insert / Replace (#20686) 2020-11-17 15:19:04 +08:00
b2e6df07c8 session: Support Variable-Setting Hint SET_VAR (#20232) 2020-10-28 14:27:13 +08:00
713c2378f6 planner: let SQL BINDING support UNION ALL/INTERSECT/EXCEPT (#20010) 2020-09-27 13:58:37 +08:00
1c842919eb executor: fix hint not working in prepared statement (#19935) 2020-09-17 13:40:48 +08:00
e356136b72 *: annotate execution info in runtime/trace (#19407)
Co-authored-by: ti-srebot <66930949+ti-srebot@users.noreply.github.com>
2020-08-27 11:23:36 +08:00
75ebe66a0b planner: fix IsPointGetWithPKOrUniqueKeyByAutoCommit for clustered index (#19255) 2020-08-20 13:30:04 +08:00
8978773f5e planner: remove the limit that nth_plan hint value can't exceed 100 (#19037) 2020-08-10 20:31:51 +08:00
b193db8b49 planner: ban tiflash engine when the statement is not read only (#18458)
Co-authored-by: ti-srebot <66930949+ti-srebot@users.noreply.github.com>
2020-07-14 11:43:48 +08:00
dce0e45bdf planner, add hint nth_plan(x) to help user force a plan (#17850) 2020-07-01 15:34:22 +08:00
9b16427628 server: prefetch point-get keys for multi-statement queries. (#18155) 2020-06-23 13:13:18 +08:00
b59cb1a94d planner, session, util: support Insert hint (#16966) 2020-06-17 15:56:01 +08:00
405a5d009d sessionctx: add optimization-time and wait-TS-time into the slow log (#17869) 2020-06-10 10:41:50 +08:00
0ec197fae0 sessionctx: add some information about the rewriting phase into the slow log (#17569) 2020-06-09 13:49:42 +08:00
d53336bd4a planner: support sql_select_limit session / global variable (#17444) 2020-06-02 18:02:29 +08:00
8a164d2cce planner: improve the error message for hints defined more than once (#16301) 2020-06-01 23:21:18 +08:00
7ca3d9cadc bindinfo, record how bindings are created in SQL bindings. (#17254) 2020-05-27 09:56:40 +08:00
746c88a461 bindinfo, planner: make evolve tasks consider runtime hints instead of ignoring them (#15668) 2020-03-31 20:30:23 +08:00
2619f02ddd *: move hint and block hint processor to util directory (#15897) 2020-03-31 16:37:45 +08:00
08c4c665fd session: initialize session bind handler when creating session according to createSessionWithOpt (#15724) 2020-03-30 14:48:10 +08:00
71cf7e92f1 bindinfo: build ID of BindRecord from Hint instead of explain query (#15781) 2020-03-30 14:40:43 +08:00
7223e7f8c9 bindinfo, planner: fix TiFlash compatibility with binding and SQL plan management (#15719) 2020-03-27 15:44:15 +08:00
c1e44a7818 planner: don't choose point get when none tikv in isolation read (#15147) 2020-03-27 10:27:27 +08:00
4112f1c25b planner/bindinfo: fix occasional panic of baseline evolution (#15233) 2020-03-19 21:10:53 +08:00
af861eeba2 planner: support hint USE_CASCADES(true|false) to use/disuse cascades planner in a single query (#15352) 2020-03-16 19:35:24 +08:00
248be5bba5 planner: push down Lock to PointGet and BatchPointGet (#15257) 2020-03-11 13:58:32 +08:00
7fa56616f8 executor: refactor the tso future in RC isolation (#14966) 2020-03-02 15:38:10 +08:00
1c0974064d planner: adapter the generic hint struct TableOptimizerHint (#14835)
Signed-off-by: Lonng <heng@lonng.org>
2020-02-18 21:08:19 +08:00
40a6be1a82 bindinfo: handle statement hints in bindings (#14248) 2020-01-07 14:18:46 +08:00
e755459788 bindinfo: change the way of generate hints from sql (#14095) 2020-01-02 14:31:39 +08:00
447cfbd067 bindinfo: fix bugs when capture and evolve plans (#14206) 2019-12-28 20:35:39 +08:00
635f2e1afd bindinfo: set default db for bindings correctly (#14077) 2019-12-27 18:02:09 +08:00
1335ffb6b7 *: support read consistency isolation level in the pessimistic transactions (#14087) 2019-12-24 21:24:39 +08:00
39a370ce83 bindinfo: support drop bindings of dropped table (#14071) 2019-12-19 14:51:46 +08:00
dddb85ca92 bindinfo: remove last semicolon of bind sqls (#14110) 2019-12-18 15:35:46 +08:00
b743208fd7 bindinfo, planner: fix sql bind when sql has symbol list (#13889) 2019-12-07 14:26:08 +08:00
518692c14c bindinfo: support evolve plan (#13465) 2019-11-22 17:09:37 +08:00
58733475da *: support capture evolve plan tasks (#13199) 2019-11-13 16:22:48 +08:00
343bb640a0 bindinfo: support drop specific binding (#13245) 2019-11-13 12:32:24 +08:00
5c5aa104d9 *: support using multiply bindings in planner (#13047) 2019-11-05 16:38:15 +08:00
36f0f37b40 expression, planner: remove some fields from `expression.Colum… (#12573) 2019-10-29 15:48:26 +08:00
bb2e349fea bindinfo: support multiply bindings for a sql (#12851) 2019-10-29 14:40:23 +08:00
740b7769b0 *: support automatically create sql baselines (#12434) 2019-10-17 14:16:48 +08:00
20823fbe18 *: add a system variable to control the usage of baselines (#12624) 2019-10-14 21:09:03 +08:00
86d9db7736 planner/cascades: support parameterized transformation/implementation rules (#12376)
* wrap the transformation/implementation rules in the struct of optimizer

* fix unit tests

* address comment

* minor change, keep the same code style

* add default singleton optimizer
2019-09-25 20:31:38 +08:00
15011b6c49 executor: new execution path for point execution within prepared plan cache (#11970) 2019-09-17 14:14:45 +08:00
dffe29355a *: not send tso request when point get with max tso (#11981) 2019-09-03 23:11:49 +08:00
3de23f0f7c planner/core: support query block hint (#11861) 2019-08-29 19:14:38 +09:00
f24866a40c *: support bindings for prepare statement (#11642) 2019-08-26 10:30:40 +08:00