Answers for "run mysql script from command line"

SQL
4

execute mysql file

mysql -u yourusername -p yourpassword yourdatabase < text_file
Posted by: Guest on June-01-2020
1

run mysql command from bash

mysql --user="$user" --password="$password" --database="$database" --execute="DROP DATABASE $user; CREATE DATABASE $database;"
Posted by: Guest on January-20-2021

Code answers related to "run mysql script from command line"

Code answers related to "SQL"

Browse Popular Code Answers by Language