in reply to Re: Executing a file of SQL commands against MySQL server
in thread Executing a file of SQL commands against MySQL server

Or, alternatively, use the -e option of the mysql client to parse the sql_file: mysql -u username -p password -e 'source sql_file' database
This will make the mysql-client read the file instead of piping it in.