Today we have done bulk import of data using csv/txt format into MS SQLServer 2012.
Procedure
- Right click on your database and select “Tasks -> Import Data”
- Click the “Next>” button
- For the Data Source, select “Flat File Source”.
- Browse and select the CSV/TXT file
- For the Destination, select the correct database provider (e.g.
for SQL Server 2012, you can use SQL Server Native Client 11.0). Enter
the Server name; check Use SQL Server Authentication, enter the User name,
Password, and Database before clicking on the Next > button.
- Change the options like delimiter, carriage return(new line), First row as header
- Spend some time configuring how you want the data to be imported before clicking on the Next > button.
- Change the table name
- Change the columns datatype
- Preview your table
- On the Select Source Tables and Views window, you can Edit Mappings before clicking on the Next > button
- Check Run immediately and click on the Next > button.
- Click on the "Finish" button to run the package
- You data with the table will be selected
Please send your feedback and comments to psrdotcom@gmail.com
Blogger Labels: Bulk,text,data,SQLServer,Procedure,database,Tasks,Import,Click,Source,Flat,File,Browse,Change,options,carriage,header,Spend,columns,Preview,Finish,Enjoy