Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2008 Forums
 Transact-SQL (2008)
 Help

Author  Topic 

sqlfresher2k7
Aged Yak Warrior

623 Posts

Posted - 2012-05-31 : 12:47:21
I have created DML,DDl script which loads the data in a table which size of 125 mb.

Is there any way to run that in query analyzer..

robvolk
Most Valuable Yak

15732 Posts

Posted - 2012-05-31 : 13:03:36
If the file is too big to run in Management Studio, you can try running it with the SQLCMD utility using the -i parameter:

sqlcmd -SmyServer -i"mySQLscript.sql"

If that still doesn't work you'll have to edit the SQL file into smaller pieces. Make sure there are no BEGIN TRANSACTION blocks that could get split between files.
Go to Top of Page

sqlfresher2k7
Aged Yak Warrior

623 Posts

Posted - 2012-05-31 : 13:27:52
Thanks Rob..

Due to file size constraints i am unable to open the scripts file in ssms.
The file size limit can be increased in ssms..Here is the link to

http://msdn.microsoft.com/en-us/library/bb964729.aspx
Go to Top of Page

robvolk
Most Valuable Yak

15732 Posts

Posted - 2012-05-31 : 13:31:54
I did not know that, now I do.
Go to Top of Page
   

- Advertisement -