문제

How to count number of tables in a database ?

SELECT COUNT *    
FROM SHOW TABLES AS A
도움이 되었습니까?

해결책 2

SELECT COUNT(*) FROM information_schema.tables WHERE table_schema = 'dbName';

다른 팁

 SELECT COUNT(*) FROM information_schema.tables WHERE table_schema = 'dbName';

Source

This one is easy

USE databasename; SHOW TABLES; SELECT FOUND_ROWS();
라이센스 : CC-BY-SA ~와 함께 속성
제휴하지 않습니다 StackOverflow
scroll top