Last active
July 25, 2024 11:11
-
-
Save vinaghost/c24e1f44d990910cf7144045ac9d823d to your computer and use it in GitHub Desktop.
drop database
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
| select CONCAT('drop database `', schema_name,'`;') as database_name from information_schema.schemata where schema_name like '%DATABASES_TO_REMOVE%' order by schema_name; |
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
| select CONCAT('echo "Importing: ', schema_name,'"\nmysql -u USERNAME -pPASSWORD ', schema_name,' < villagecrawler_migration.sql\nwait\n') as database_name from information_schema.schemata where schema_name like '%DATABASES_TO_IMPORT%' order by schema_name; |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment