I need a variable to hold results retrieved from the database. So far this is basically what I\'m trying with no success.
myvariable=$(mysql database -u $use
Another example when the table name or database contains unsupported characters such as a space, or '-'
db='data-base' db_d='' db_d+='`' db_d+=$db db_d+='`' myvariable=`mysql --user=$user --password=$password -e "SELECT A, B, C FROM $db_d.table_a;"`