How can MySQL execute SQL scripts in batches?

In MySQL, there are several methods available for executing SQL scripts in batch.

  1. Execute a script file using the MySQL command line tool.
  2. mysql -u -p
  3. Please replace , , , and