none
Not enough storage is available to complete this operation ?

Answers

  • Is that a single query that's 275 MB, or a 275 MB .sql file with many little queries? 

    If the former, I'm going to guess that it's a single large insert statement with many rows.  SQL Server won't be too fond of you trying to pass a query that large, even if you get Management Studio to load the file.

    If the latter (which I suspect it is), then you should be able to use another tool to open the .sql file, and divide the file into more manageable chunks (eg Wordpad, but make sure you're saving as plain text - perhaps just use Wordpad to select the text, then copy to Management Studio or Notepad to save).

    Alternatively, you might look at a different method of running the script - consider passing it through the command-line tool sqlcmd instead, although you might have to make some minor syntax adjustments first.  Each statement can then be run in turn, without loading the whole 275 MB file into memory (and then trying to syntax highlight it).  This is probably the best solution.
    • Marked as answer by ozsql Tuesday, December 22, 2009 1:20 AM
    Tuesday, December 22, 2009 1:11 AM

All replies

  • Hi Guys,

    I am trying to open .SQL file and I am getting following error message.

    the operation could not be completed. not enough storage is available to complete this operation.

    I went to following website:

    http://www.geekpedia.com/KB93_The-operation-could-not-be-completed.-Not-enough-storage-is-available-to-complete-this-operation..html

    But I haven't created any database yet, Query itself will create database and tbl's

    How to open this query ?

    Can someone shed soem light on this

    Thanx

    D

    Monday, December 21, 2009 11:26 PM
  • What is the size of the .sql file that you are looking to open ?

    see this https://connect.microsoft.com/SQLServer/feedback/ViewFeedback.aspx?FeedbackID=269566
    Thanks, Leks
    Tuesday, December 22, 2009 12:07 AM

  • Hi Leks's,

    The size of my query is 275 MB . I followed the link and what a shame Microsoft still hasn't fix the problem. I tried to open the query both 2005 and 2008 SQL Ent, no luck same issue.

    Is there any workaround for this.

    Thanks,

    D



    • Proposed as answer by DaveGe Thursday, July 18, 2013 7:58 PM
    Tuesday, December 22, 2009 12:38 AM
  • At the moment this bug is still acitve as you can see that from connect site, may be you can also vote for this and express your thoughts.
    For time being , just split the file in to small files of each sizing around 10 mb or 25 mb and complete your job.
    Thanks, Leks
    Tuesday, December 22, 2009 1:04 AM
  • Is that a single query that's 275 MB, or a 275 MB .sql file with many little queries? 

    If the former, I'm going to guess that it's a single large insert statement with many rows.  SQL Server won't be too fond of you trying to pass a query that large, even if you get Management Studio to load the file.

    If the latter (which I suspect it is), then you should be able to use another tool to open the .sql file, and divide the file into more manageable chunks (eg Wordpad, but make sure you're saving as plain text - perhaps just use Wordpad to select the text, then copy to Management Studio or Notepad to save).

    Alternatively, you might look at a different method of running the script - consider passing it through the command-line tool sqlcmd instead, although you might have to make some minor syntax adjustments first.  Each statement can then be run in turn, without loading the whole 275 MB file into memory (and then trying to syntax highlight it).  This is probably the best solution.
    • Marked as answer by ozsql Tuesday, December 22, 2009 1:20 AM
    Tuesday, December 22, 2009 1:11 AM
  • Tuesday, December 22, 2009 1:24 AM
  • I realize that this is an old dead post but since it comes on up google when you search the issue I figured I'd post the solution.  Use osql to run the query.  

     

    Format for the query is:

    osql -S servername -U username - P password -i C:\foldername\filename.sql

     

    That will avoid you having to open it inside of the Enterprise Manager or with the SQL Management Studio to run the script.

     

    Jose Adams

    Tuesday, July 06, 2010 4:02 AM