Following
mysql -u root -ppassword -D database -s -N -e "SELECT id FROM myTable"
with special password and database is working fine.
I want to split the code into two parts:
Executional part:
mysqlE=mysql -u root -ppassword -D database -s -N -e
and
MySQL command part:
query="SELECT id FROM myTable"
to execute it with something similar like:
mysqlE query
How would youcan I do this?