Import in SQL

sqlcmd -S SERVERNAME\INSTANCE_NAME -i C:\path\mysqlfile.sql -o C:\path\output_file.txt

oder

sqlcmd -S SERVERNAME -d MYDATABASE -U USERNAME -P PASSWORD -i C:\path\mysqlfile.sql -o C:\path\results.txt
  • -S: is your servername or localhost
  • -d: is the database you are targeting
  • -U: is the username
  • -P: is the password
  • -i: is the path to your .sql file
  • -o: is where the logs file will be saved so if you had problem during the importation you can debug them