zoukankan      html  css  js  c++  java
  • mysql依据某一张表的字段,查询出对应的表所在的数据库

    表太多,只记得这个表有一个mygame的字段,但是并不知道这张表在那个数据库下,只能根据这个字段查找对应的表和所在数据库

    select table_schema,table_name from information_schema.columns where column_name = '字段名'

    演例:

    mysql> select table_schema,table_name from information_schema.columns where column_name = 'gname';

    查询结果:
    +--------------+-------------------+
    | table_schema | table_name        |
    +--------------+-------------------+
    | ccc          | mygame            | # 可知道在ccc这个数据库下
    | student      | app01_class_grade |
    +--------------+-------------------+
    2 rows in set (0.36 sec)
  • 相关阅读:
    event.currentTarget
    architecture 20190628
    jQuery extend
    Prototype js library
    this._super()
    cdn for js library
    WAMPSERVER php
    characteristics of competent communicators
    onchange and oninput
    jQuery .ready()
  • 原文地址:https://www.cnblogs.com/one-tom/p/11213590.html
Copyright © 2011-2022 走看看