in reply to sql editor written in perl
In practice, we can do things at the commandline, like:
Similarly, we can easily get to the shell via,# send some SQL: $ ourutil dbname < some.sql $ cat some.sql | ourutil dbname $ echo "SELECT * ..." | ourutil dbname # dump out stuff $ ourutil -D dbname [table] -- [extra mysqldump options]
And if we just want to print the command string with the auth information in + options it would have executed, we can do:$ ourutil dbname
I wish I could share the code, but the above interface should be readily implemented and customized to fit your existing environment. Update: just wanted to add, this utility I describe rarely changes and is extremely useful on a daily basis.$ ourutil --cmd # for mysql, or $ ourutil -D --cmd # for mysqldump
|
---|