Commit Graph

93 Commits

Author SHA1 Message Date
6a984412c7 ddl: use original column name in duplicate column error (#9291) 2019-02-14 13:15:15 +08:00
5c65128632 ddl: make the leak test stable (#9139) 2019-01-23 13:01:55 +08:00
63936cc1fa ddl: resolve the charset by the order: table->database->server (#9105) 2019-01-21 19:56:40 +08:00
ec833bc4d2 *: fix some lints produced by golangci-lint (#8999) 2019-01-16 16:44:49 +08:00
e06c87d3c1 add an option for AddRecord and Create (#8884) 2019-01-02 11:30:53 +08:00
a7907ede7a *: remove fail field from TxnState (#8712)
Originally, `fail` is added to simplify error handling, avoiding large changes on
the Txn() interface API. But it turns out that `fail` becomes the root of many bugs.
So this commit remove the `fail` and make an API refactory.
2018-12-20 16:36:12 +08:00
4e8c424718 *: basic support for CREATE_VIEW (#8571) 2018-12-18 20:17:27 +08:00
db2127a0dd ddl: split tests to speed up tests (#8612)
* ddl: add the db_partition_test
2018-12-13 15:06:04 +08:00
1d7d01cfe8 ddl: support altering the other charset to utf8 or utf8mb4 (#8037) 2018-12-10 12:58:18 +08:00
93acd10f53 *: add context.Context to NewTxn(), tiny refactor (#8530) 2018-12-06 17:45:16 +08:00
c137cada68 *: change golang.org/x/net/context to standard context (#8579) 2018-12-05 13:54:00 +08:00
3742a0d602 *: Txn() function signature refactor and remove ActivePendingTxn() (#8327)
* change Txn() function signature to Txn(active bool)
* ActivePendingTxn() is not used any more because Txn() does the work
* change executor builder getStartTS() uint64 to getStartTS() (uint64, error)
2018-11-16 11:10:39 +08:00
29f14d4178 *: change default charset and collation from 'utf8 utf8_bin' to 'utf8mb4 utf8mb4_bin' (#7965) 2018-11-09 16:32:21 +08:00
32b1dbd8d5 *: rename "github.com/pkg/errors" to "github.com/pingcap/errors" (#8136)
We import "github.com/pkg/errors" in the code, and actually put
the "github.com/pingcap/errors" there in the vendor path.
That's a dirty hack, and prevent the introduce of Go module.
2018-11-01 16:09:07 +08:00
89dda9d9a8 *: move parser to a separate repository (#8036) 2018-10-25 11:12:10 +08:00
cb03f2bec1 move from juju/errors to pkg/errors (#7151) 2018-09-12 15:42:20 +08:00
58248563bc ddl: add primary key default value check when create table (#7169) 2018-07-31 15:44:11 +08:00
da6f0c1edd ddl: initial support for parallel DDL (#6955) 2018-07-25 10:48:38 +08:00
7c18d24933 executor, store: fixed daylight saving time issue (#6823)
Thank you for working on TiDB! Please read TiDB's [CONTRIBUTING](https://github.com/pingcap/tidb/blob/master/CONTRIBUTING.md) document **BEFORE** filing this PR.

## What have you changed? (mandatory)

During coprocessor dag task,  it first uses timezone `name`, if non-empty, to get legitimate timezone variable. To achieve this, we need to push down such data into tikv which leads to change the logic of building pushdown request. The logic I mentioned mainly resides in `executor` package. 

I change `timeZoneOffset` to `zone` and add second return parameter `name string`.  The intentioned of doing this to adopt the convention of `time` package. 

For the same purpose, I change `GetTimeZone` to `Location`. As you can see, in `time` package, timezone was bind to `Location`. 


## What are the type of the changes (mandatory)?
- Bug fix (non-breaking change which fixes an issue)


## How has this PR been tested (mandatory)?
unit-test
integration-test will be added shortly
2018-07-16 18:15:19 +08:00
42675d97fb ddl: adjust the structure of ddl (#6449) 2018-06-14 17:13:50 +08:00
7de583383c ddl: make testleak be more stable. (#6224) 2018-04-04 20:33:48 +08:00
e1121814d2 *: don't import golang.org/x/net/context as goctx alias (#5895)
Now that there is no conflict with sessionctx.Context, this can be
import directly
2018-02-24 03:40:56 -06:00
4e1a114e68 *: move package context to sessionctx (#5890) 2018-02-22 18:03:38 +08:00
14ed94132c executor: fix issue #5132, update handle id with some other unique keys report Duplicate keys. (#5138) 2017-11-20 11:06:28 +08:00
1630957fdf parser: Support add columns with parentheses (#5103) 2017-11-16 15:07:48 +08:00
62433663e5 util/types: change types path (#5007)
* util/types: change types path
2017-11-04 10:37:14 -05:00
37681cf435 *: opentracing for two phase commit (#4900) 2017-10-26 17:43:45 +08:00
64b5bc8ccd mysql,ddl: fix #4684, unsigned integer column length is not consistent with MySQL (#4693) 2017-10-09 17:24:37 +08:00
1eebb87156 ddl: remove backgroud worker, use delete-range to speed up something. (#3993) 2017-08-09 16:59:25 +08:00
5943198358 *: Add the two states test (#3804)
* ddl: add different state tests

* ddl: update

* ddl: clean up

* ddl: add a comment

* ddl: make more readable

* ddl: add a comment

* ddl: add the error check

* ddl: address comments
2017-07-26 00:24:56 +08:00
2518f8548a *: Add the arguments of ctx and etcdCli to the NewDDL interface (#3302) 2017-05-22 16:11:05 +08:00
0d6490efc4 *: interpret timestamp datum based on session's time_zone (#3167)
1. FromPackedUint don't consider time_zone any more, moved to Unflatten
2. use session's time_zone instead of time.Local
3. add a time.Location parameter to some Encode/Decode functions in tablecodec
2017-05-08 11:58:55 +08:00
9f3ed9bc05 ddl: fix checkDuplicateColumn and add test cases. (#3174) 2017-05-03 17:03:24 +08:00
59154905aa *: rename table-driven tests name. (#3081) 2017-04-19 10:02:57 +08:00
5434d8046e ddl: add the reason for the unsupported modify column error. (#3078) 2017-04-18 20:50:20 +08:00
d215257ea9 ddl: set collate if not set.
Should set column collate to default one if charset is set but collation is not set.
2017-03-21 19:52:03 +08:00
fb9cd85e2e *: Speed up the add columns phase (#2769) 2017-03-07 20:11:29 +08:00
19af8d720f ddl: Add the function of close (#2562)
add the function of close, use Stop instead of close and add log.
2017-01-26 13:23:27 +08:00
f386df1020 ddl: avoid assert in lock (#2482)
assert in lock may cause dead lock
2017-01-17 13:09:49 +08:00
d3f0612263 ddl: avoid assert in hook function. (#2479) 2017-01-16 16:38:29 +08:00
6bc6f7e98b *: Add the field of history information in job structure (#2046) 2017-01-05 16:34:39 +08:00
2248b6226b ddl: Add a ddl_op file (#2324)
* ddl: add a ddl_api file
2016-12-26 14:31:01 +08:00
64484a4257 *: refactor context.Context (#2298)
Make transaction life cycle under control, prepare for correctly handle schema out of date error.
The old `GetTxn(forceNew boll)` is replaced by `Txn` and `NewTxn`,
`CommitTxn` and `RollbackTxn` is removed.
2016-12-23 13:02:41 +08:00
99b3465c1e ddl: allocate column ID and index ID in TableInfo. (#2205) 2016-12-09 12:31:27 +08:00
196b6b18fe *: Support for changing column (#2174)
*: support for changing column in parser
* ddl: support for changing column in ddl
2016-12-07 11:19:37 +08:00
1056c56df1 ddl: support modify column (#1930)
* ddl: support modify column
2016-11-08 15:20:41 +08:00
3f2f6306bc ddl: remove useless test and adjust test position (#1891) 2016-10-30 22:53:46 +08:00
64e181286a ddl: Add table infomation and schema version to history job (#1857) 2016-10-24 14:58:17 +08:00
5df5085e33 *: Add row count field in a job, fix a drop schema bug and pass race (#1759) 2016-09-28 18:11:40 +08:00
42010e61db fix typo and ineffassign (#1702)
* fix typo and ineffassign
2016-09-07 01:57:58 -05:00