mysql -u yourUserName -p yourDatabaseName < yourFileName.sql
sqlplus username/password@service -- OR sqlplus / as sysdba
SQL> SELECT sysdate FROM dual;
SQL> @C:Usersfolderscript.sql
-- OR
SQL> START C:Usersfolderscript.sql
sqlplus username/password@service -- OR sqlplus / as sysdba
SQL> SELECT * FROM dual;
/*in Sql Server (SSMS)*/
/*Hightlight the statements you would like to execute*/
/*Then click on the green play button (somtimes with the word execute) or press F5*/