MySQL查询数据库中没有主键的表

  1. select table_schema,table_name from information_schema.tables
  2. where (table_schema,table_name) not in(
  3.     select distinct table_schema,table_name from information_schema.columns where COLUMN_KEY='PRI'    
  4. )
  5. and table_schema not in (
  6.     'sys','MySQL','information_schema','performance_schema'
  7. );


分享题目:MySQL查询数据库中没有主键的表
标题URL:http://www.hxwzsj.com/article/pdhgpg.html

其他资讯

Copyright © 2025 青羊区翔捷宏鑫字牌设计制作工作室(个体工商户) All Rights Reserved 蜀ICP备2025123194号-14
友情链接: 梓潼网站设计 成都网站建设公司 网站建设推广 成都网站设计 成都模版网站建设 高端网站设计 重庆网站制作 营销型网站建设 企业手机网站建设 成都商城网站建设 成都网站建设 成都网站设计 移动网站建设 重庆手机网站建设 网站制作报价 定制网站建设 手机网站建设套餐 成都网站制作公司 高端网站设计推广 达州网站设计 成都响应式网站建设 成都网站制作