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
'load data' is not retryable when it meets conflicts, while latches may result in
false positive transaction conflicts. so enable latches will lead to 'load data'
abort abnormally, even there are no conflicts.
tidb diff result with mysql when mix use union and union-all fix#6731
- rename `selectStmt.UnionDistinct` to `selectStmt.IsAfterUnionDistinct`
- add explain test
- remove useless `unionStmt.Distinct` and `selectList.Distinct`
- refactor use golang slice, remove dup code
- return WrongNumColumnInSelect error and add test case
If for update appears after order by or limit in union, then it is ignored.
If there is no order by or limit, it affects only the near select statement.
This locks both statements.
```
select * from t for update union select * from s for update;
```
This is syntax error:
```
(select * from t) union all (select * from s) for update;
```
copIterator.Close() closes finished channel and wait for worker goroutines to
exit, worker goroutine send response to channel but nobody receive from the
channel (copIterator already closed), so those goroutine leak and Close() function
hang forever.
Change the worker goroutine to check both response channel and finished channel.