Need to create new database without using management studio

remo picture remo · Jul 9, 2010 · Viewed 53.8k times · Source

How to create new database with SQL Server Express 2008 without using Management Studio?

Do i need to download sp1?

Answer

Chris Diver picture Chris Diver · Jul 9, 2010

You can use the SqlCmd utility from the command line to execute SQL.

Open a command prompt and then type SqlCmd.exe and press enter, you should then get 1) which means you are connected.

Once connected execute

1) CREATE DATABASE dbname
2) GO