How to pass a parameter to mysqlsh shell command?

34 views Asked by At
mysqlsh --host=127.0.0.1 --port=3306 --user=root --password=rootpw 
         --file my.js $tableName

How can I pass the $tableName parameter dnymically ot the my.js file?

I tried first reading the argument in the js file, but that already fails:

print("Table name:", argument[0]);

How can arguments be accessed?

0

There are 0 answers