Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 General SQL Server Forums
 New to SQL Server Programming
 about csv file

Author  Topic 

Haya2013
Starting Member

4 Posts

Posted - 2013-02-04 : 02:18:53
Hi,,

I am a new member in ure forum and also a new in sql server 2005 and sql server managment studio,,
I create a web site with sql server 2005 express then I want to upload it but I face a problem while upload the database file they tell me that I should create the database in the hosting server then build the tables and fields then import csv file for each table is this mean importing data using csv file and how I could do it using sql server managment studio.

Regards,
Haya

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2013-02-04 : 03:02:00
you've use export import wizard. But its not available with sql server express. you've to get standard edition for that

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page

Haya2013
Starting Member

4 Posts

Posted - 2013-02-04 : 03:25:22
plz I couldnt have the standard edition is there else way to do that

also what about database publishing wizard can it upload the database to the site?

Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2013-02-04 : 03:29:10
thats for creating (publishing) a databse onto a hosting server. it will script out the db which you can use for creating in server

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page

Haya2013
Starting Member

4 Posts

Posted - 2013-02-04 : 05:42:32
Thanx for replying

Can I write a select statement to get all data from my file to save them into output file then save this file as csv to use it
Go to Top of Page

James K
Master Smack Fu Yak Hacker

3873 Posts

Posted - 2013-02-04 : 05:46:56
You can use BCP command to save the data from a table to a file. There are some good examples on this page http://msdn.microsoft.com/en-us/library/ms162802(v=sql.105).aspx If you are using SQL Express, your servername would be (local)\SQLExpress or Servername\SQLExpress
Go to Top of Page

visakh16
Very Important crosS Applying yaK Herder

52326 Posts

Posted - 2013-02-04 : 06:21:36
quote:
Originally posted by Haya2013

Thanx for replying

Can I write a select statement to get all data from my file to save them into output file then save this file as csv to use it


all data from all tables onto a single file?

------------------------------------------------------------------------------------------------------
SQL Server MVP
http://visakhm.blogspot.com/

Go to Top of Page

Haya2013
Starting Member

4 Posts

Posted - 2013-02-04 : 08:26:07
quote:
Originally posted by James K

You can use BCP command to save the data from a table to a file. There are some good examples on this page http://msdn.microsoft.com/en-us/library/ms162802(v=sql.105).aspx If you are using SQL Express, your servername would be (local)\SQLExpress or Servername\SQLExpress



I can select data from each table then save them as csv file then import them into the table which be in hosting server since I havent sql server managment studio standard edition
Go to Top of Page

James K
Master Smack Fu Yak Hacker

3873 Posts

Posted - 2013-02-04 : 09:07:53
Yes, you can do that one file at a time. You can run BCP commands from a command line one at a time, or you can put the commands for all the files into a single cmd file and run that cmd file.
Go to Top of Page
   

- Advertisement -