How to create new database with SQL Server Express 2008 without using Management Studio?
Do i need to download sp1?
If there is no need for user interface and the command line is OK then we can use SQLCMD tool. This tool can be downloaded by searching “SQL Server feature pack” in any search engine. Here are the results as of today in google. Based on your need, you can choose the version.
Select Databases from the SQL navigation menu. Click Create database. In the New database dialog, specify the name of the database. Click Create.
On the Edit menu, point to Find and Replace, and then click Quick Replace to open the dialog box with both find options and replace options. Toolbar buttons and shortcut keys are also available to open the Find and Replace dialog box.
Right-click Databases, and then select New Database. In New Database, enter a database name. To create the database by accepting all default values, select OK; otherwise, continue with the following optional steps. To change the owner name, select (...) to select another owner.
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
Use CREATE DATABASE via sqlcmd or another other database connection (even VBA from Excel...)
If you love us? You can donate to us via Paypal or buy me a coffee so we can maintain and grow! Thank you!
Donate Us With