Re: Connect shell and mysql
- From: "Radoulov, Dimitre" <cichomitiko@xxxxxxxxx>
- Date: Tue, 19 Jun 2007 13:37:33 +0200
rahismailbox wrote ...
} hi,
} how to write and connect to mysql using shell script?
$ mysql -u username -ppassword < <(printf "show databases;")
Database
information_schema
mysql
test
If your shell doesn't support process substitution (<()) use printf ... |
mysql ...
Dimitre
.
- References:
- Connect shell and mysql
- From: rahismailbox@xxxxxxxxx
- Connect shell and mysql
- Prev by Date: Re: compair files
- Next by Date: Re: AWK problem need help
- Previous by thread: Connect shell and mysql
- Next by thread: AWK problem need help
- Index(es):
Relevant Pages
|