Wednesday, October 9, 2013

How to import/export data in SQL Server from one to other

Transferring database or data from development machine to production machine is very common thing in deployment stage.

I will show you steps to do that.

Open Microsoft SQL Server Management Studio, select your database, right click on it and select Import Data.

On this step you need to choose a Data Source, give the Server name and authentication and select source database from server. If authentication is correct it will automatically show you the list of databases available on up given server.

Before step you should already create a database where you want to transfer the data. 
Next choose destination where you want to transfer your data again same steps as mentioned above.

Wizard will show table and views available in both databases. Select table you want import from source to destination. Click on Edit Mappings and selection required options. 

Here one thing is notable if you don't have tables created in destination database you still able to transfer and create tables but in case you will loose your all keys and index which you need to setup again on destination database.

Click finish and it will start transferring tables.

Author Qasim Sarfraz

No comments:

Post a Comment