当前位置:网站首页>mysql如何查看所有复合主键的表名?
mysql如何查看所有复合主键的表名?
2022-08-09 16:58:00 【薛晓刚】
mysql如何查看所有复合主键的表名?
采纳答案1:
查询 mysql.indexes里面

其他答案1:
查询 mysql.indexes里面

其他答案2:
SELECT
*
FROM
(SELECT
TABLE_SCHEMA, TABLE_NAME, COUNT(COLUMN_KEY) AS count_pri_col
FROM
information_schema.COLUMNS
WHERE
COLUMN_KEY = 'PRI' and TABLE_SCHEMA not in ('mysql')
GROUP BY TABLE_SCHEMA , TABLE_NAME) AS aa
WHERE
aa.count_pri_col > 1;
边栏推荐
- win10 uwp 模拟网页输入
- The most complete architect knowledge map in history
- win10 uwp 让焦点在点击在页面空白处时回到textbox中
- 怎样选择一个好的SaaS知识库工具?
- win10 uwp 设置启动窗口大小 获取窗口大小
- [SUCTF 2019]CheckIn
- 毕昇编译器优化:Lazy Code Motion
- dotnet 6 为什么网络请求不跟随系统网络代理变化而动态切换代理
- JMeter笔记6 | JMeter录制(配置代理)
- [Code Audit] - PHP project class RCE and files include download and delete
猜你喜欢
随机推荐
SkiaSharp 之 WPF 自绘 投篮小游戏(案例版)
Apache Doris 社区 PMC 杨政国:开源项目如何在自身和社区的需求中取得平衡?
JMeter notes 6 | JMeter recording agent (configuration)
The most complete architect knowledge map in history
Jenkins deploys services to remote servers using pipelines
【解决】虚拟机VMware通过局域网连接机器人no route to host
FAST-LIO2代码解析(三)
学长告诉我,大厂MySQL都是通过SSH连接的
.NET Community Toolkit 8.0.0 版本发布
win10 uwp 活动磁贴
方舟单机/管理员特殊物品指令代码大全
API接口是什么?API接口常见的安全问题与安全措施有哪些?
Entry node of ring in leetcode/linked list
EPIC是什么平台?
太细了!阿里大佬耗时39天整理出一份Redis进阶笔记,满满的干货
crm系统哪家好?好用的crm管理系统推荐
Logic unauthorized and horizontal and vertical unauthorized payment tampering, verification code bypass, interface
openEuler Xiong Wei: How do you view the SIG organization model in the open source community?
动态RDLC报表(五)
试试使用 Vitest 进行组件测试,确实很香。







![[SUCTF 2019]CheckIn](/img/4a/cae4dbe47c3b9d0fb37fe337bb5c3f.png)
