Sometimes we need to run large sql script which has 1-10 gb size or something etc. then we won't be open this .sql file in sql, notepad, etc.
In this case, we need to run this command without any problem in easiest way, we can use commandline sqlcmd command to run our sql commands.
To do this operation, just follow few steps ;
- Click Windows + R
- type cmd and press enter to reach commandline
- use command to run your file :)
In my scenario , I runned 8 GB .sql file with this method then it will completed successfuly without wasting memory or cpu while doing its job.