#!/bin/sh

mysql -u $1 -p  <<EOF

use $2

$3

commit;

EOF