Last active
May 17, 2018 12:20
-
-
Save Eidansoft/65a514beb0cb76f8548db8146599a87d to your computer and use it in GitHub Desktop.
Generic SQLs to easily solve some issues
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Look for a table filtering by the name (MySql) | |
-- If you already has the database selected | |
SHOW TABLES LIKE '%_name' | |
-- If the database is not selected | |
SELECT TABLE_NAME | |
FROM INFORMATION_SCHEMA.TABLES | |
WHERE TABLE_NAME like '%_name' | |
and TABLE_SCHEMA = 'your_db_name' |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment