I use RedGate SQL data compare and generated a .sql file, so I could run it on my local machine. But the problem is that the file is over 300mb, which means I can’t do copy and paste because the clipboard won’t be able to handle it, and when I try to open the file in SQL Server Management Studio I get an error about the file being too large.
Is there a way to run a large .sql file? The file basically contains data for two new tables.
From the command prompt, start up
sqlcmd:Just replace
<server>with the location of your SQL box and<your file here>with the name of your script. Don’t forget, if you’re using a SQL instance the syntax is:Here is the list of all arguments you can pass sqlcmd: