University Crest

[wlug] CLI help

 
wlug archive index About the wlug list Mailing lists home
To The University of Waikato HomepageWaikato Home > Waikato Mailing Lists > wlug Info > wlug archives
Daniel Lawson daniel@m...
Tue Mar 9 16:31:47 NZDT 2010


Cameron Rangeley wrote:
> Thanks
>
> I just tried the following variations with the following results.
>
> ARGON:/home # find /path/* -name "*.sql" -exec mysql -p password -h < {} \;
> -bash: {}: No such file or directory
>   

You need to escape the <, or else bash parses it directly and tries to 
use {} \; as an input to find, which clearly makes no sense.

find /path/* -name "*.sql" -exec mysql -p password -h \< {} \;


This is almost, but not quite the same as the solution liz proposed - 
which also works in this situation, but may not elsewhere.





More information about the wlug mailing list
NOTICE: This is an archive of a public mailing list. The University of Waikato is not responsible for its contents.

The University of Waikato - Te Whare Wananga o Waikato