Guest User

Untitled

a guest
Jun 3rd, 2018
240
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.91 KB | None | 0 0
  1. mysql:/home/rob/cli-scripts# bash -x myloop -d nowcom_nl -e "SELECT COUNT(*) AS rows FROM %q"
  2. + usage='Usage: myloop [-h] [-v] [-a] [-o] [-d database] [-t table] [-e statement]'
  3. + read -p 'Enter username: ' username
  4. Enter username: root
  5. + read -p 'Enter password: ' -s password
  6. Enter password: + echo ''
  7.  
  8. + exclude_databases=(information_schema mysql)
  9. + getopts hvaod:t:e: opt
  10. + case "$opt" in
  11. + declare -r do_database=nowcom_nl
  12. + getopts hvaod:t:e: opt
  13. + case "$opt" in
  14. + declare -r 'stmt_db=SELECT COUNT(*) AS rows FROM %q'
  15. + getopts hvaod:t:e: opt
  16. + IFS='
  17. '
  18. + read -a databases
  19. ++ mysql -uroot -pIgabish -s --skip-column-names -e 'SHOW DATABASES'
  20. + for database in '"${databases[@]}"'
  21. + isIn information_schema information_schema mysql
  22. + local pattern=information_schema element
  23. + shift
  24. + for element in '"$@"'
  25. + [[ information_schema = information_schema ]]
  26. + return 0
  27. mysql:/home/rob/cli-scripts#
Add Comment
Please, Sign In to add comment