USE

    UseStmt:

    DBName:

    1. Reading table information for completion of table and column names
    2. You can turn off this feature to get a quicker startup with -A
    3. Database changed
    1. SHOW TABLES;
    1. +-------------------------+
    2. | Tables_in_mysql |
    3. +-------------------------+
    4. | GLOBAL_VARIABLES |
    5. | bind_info |
    6. | columns_priv |
    7. | default_roles |
    8. | gc_delete_range |
    9. | gc_delete_range_done |
    10. | global_priv |
    11. | help_topic |
    12. | opt_rule_blacklist |
    13. | role_edges |
    14. | stats_buckets |
    15. | stats_feedback |
    16. | stats_histograms |
    17. | stats_meta |
    18. | stats_top_n |
    19. | tables_priv |
    20. | tidb |
    21. +-------------------------+
    22. 20 rows in set (0.01 sec)
    1. Query OK, 0 rows affected (0.10 sec)
    1. USE newtest;
    1. Database changed
    1. Empty set (0.00 sec)
    1. CREATE TABLE t1 (a int);
    1. Query OK, 0 rows affected (0.10 sec)
    1. +-------------------+
    2. | Tables_in_newtest |
    3. +-------------------+
    4. | t1 |
    5. +-------------------+

    USE 语句与 MySQL 完全兼容。如发现任何兼容性差异,请在 GitHub 上提交 。