×

Welcome to TagMyCode

Please login or create account to add a snippet.
1
0
 
0
Language: Bash
Posted by: Roman Ignatov
Added: Nov 24, 2016 4:30 PM
Views: 12
Tags: mysql sysadmin
  1. mysql -u USER -pPASS -e 'show databases;'
  2.     | grep some_dbNamePart
  3.     | xargs -I "@@" mysql -u USER -pPASS -e "DROP database \`@@\`"