Importing a 30GB .sql database dump from MySQL (--compatible=mssql) format into SQL Server 2014.

I ran 

sqlcmd -i "C:\locationoffile\database.sql"

And after it finished my harddrive had some space taken up (which I will assume is the imported database)

My issue is that when I go into the management studio there is no new database... 

where did the memory go?

August 27th, 2015 5:26pm

So what did the CREATE DATABASE statement in the SQL file say? What did the USE statement say?

If there wasn't any USE statement, everything was executed in your default database which is likely to be the master database. You have some cleaning up to do...

You create the database in advance, and add the -d option to SQLCMD to specify that database.

Free Windows Admin Tool Kit Click here and download it now
August 27th, 2015 5:40pm

I just used a log reading software to check the file. It does not have a CREATE DATABASE statement at all. It starts with DROP TABLE IF EXISTS;

Now I am really wondering where all that memory went...

August 27th, 2015 5:43pm

I just used a log reading software to check the file. It does not have a CREATE DATABASE statement at all. It starts with DROP TABLE IF EXISTS;

Well, if there is no CREATE DATABASE in the file, there will be no database created.

Now I am really wondering where all that memory went...

I told you: the master database. And that is not where you want it.

Free Windows Admin Tool Kit Click here and download it now
August 27th, 2015 5:45pm

Ok last question, I just took a look in the master and it has no extra tables inside System Databases/master/Tables/...

Is there somewhere else I need to look?


  • Edited by dimitryr 9 hours 20 minutes ago
August 27th, 2015 5:46pm

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics