Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DROP TABLE IF EXISTS behavior difference #7867

Closed
morgo opened this issue Oct 10, 2018 · 2 comments · Fixed by #14807
Closed

DROP TABLE IF EXISTS behavior difference #7867

morgo opened this issue Oct 10, 2018 · 2 comments · Fixed by #14807

Comments

@morgo
Copy link
Contributor

morgo commented Oct 10, 2018

Bug Report

Please answer these questions before submitting your issue. Thanks!

  1. What did you do?
    If possible, provide a recipe for reproducing the error.
tidb> drop table if exists idontexistatall;
Query OK, 0 rows affected (0.00 sec)
  1. What did you expect to see?
mysql57> drop table if exists idontexistatall;
Query OK, 0 rows affected, 1 warning (0.00 sec)

mysql57> show warnings;
+-------+------+--------------------------------------+
| Level | Code | Message                              |
+-------+------+--------------------------------------+
| Note  | 1051 | Unknown table 'test.idontexistatall' |
+-------+------+--------------------------------------+
1 row in set (0.00 sec)
  1. What did you see instead?

TiDB does not return a warning in the scenario the table didn't exist.

  1. What version of TiDB are you using (tidb-server -V or run select tidb_version(); on TiDB)?
MySQL [test]> select tidb_version()\G
*************************** 1. row ***************************
tidb_version(): Release Version: v2.1.0-rc.3-25-g3104c8723
Git Commit Hash: 3104c87230600e7514b3a7190689ebea30a1d8ee
Git Branch: newmaster
UTC Build Time: 2018-10-10 02:41:43
GoVersion: go version go1.11 linux/amd64
Race Enabled: false
TiKV Min Version: 2.1.0-alpha.1-ff3dd160846b7d1aed9079c389fc188f7f5ea13e
Check Table Before Drop: false
1 row in set (0.00 sec)

This bug does not affect any programs to my knowledge, but is a nice to have compatibility issue.

@shenli
Copy link
Member

shenli commented Oct 11, 2018

@winkyao PTAL

@ciscoxll ciscoxll self-assigned this Oct 11, 2018
@zhexuany
Copy link
Contributor

@ciscoxll Please update a timeline to fix this issue.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment