shell 操作mysql
时间:2021-07-01 10:21:17
帮助过:21人阅读
#!/bin/bash
2 user=
"root"
3 password=
"XXXXXX"
4 sql = `mysql -u
$user -p
$password <<
EOF 2>dev/
null
5 use mysql;
6 select *
from user;
7 exit;
8 EOF`
9 echo
$sql
shell 操作mysql
标签:log 操作 null shell password rom mysql bash class