Solved

I have SQL Server 2005 Management Studio Express and need to export a table to CSV.  How can I Do this?

Posted on 2008-10-09
7
1,092 Views
Last Modified: 2012-05-05
I have SQL Server 2005 Management Studio Express installed on my machine.  I need to export a table in our DB to CSV format.  How can I do this?
0
Comment
Question by:dkcoop03
  • 5
  • 2
7 Comments
 
LVL 5

Expert Comment

by:Cvijo123
ID: 22681084
Position yourself at your database in Managment studio then right click on database name then Tasks -> Export data

after that should be simple just follow wizard and u are done.
0
 

Author Comment

by:dkcoop03
ID: 22681353
Management Studio Express does not have the Export data option on the Tasks menu.  I was wondering if there was another way to do it.
0
 
LVL 5

Expert Comment

by:Cvijo123
ID: 22681614
do you mybe have bcp.exe file ?
(located whre u installed your SQL Server .. usually in
C:\Program Files\Microsoft SQL Server\90\Tools\BinnC:\Program Files\Microsoft SQL Server\90\Tools\Binn )

0
How your wiki can always stay up-to-date

Quip doubles as a “living” wiki and a project management tool that evolves with your organization. As you finish projects in Quip, the work remains, easily accessible to all team members, new and old.
- Increase transparency
- Onboard new hires faster
- Access from mobile/offline

 

Author Comment

by:dkcoop03
ID: 22681633
I do have the bcp.exe file but the database where the table resides is on a different server.  How, using BCP, do I specify a server?  I use Windows authentication to connect to the DB in Mgmt Studio Express, but I haven't found any syntax that tells me how to specify a remote server in bcp.
0
 
LVL 5

Expert Comment

by:Cvijo123
ID: 22681683
should be same way u do it in management studio (ip or name)
BCP master..sysobjects out c:\sysobjects.txt -c -t; -T S<servername>

Open in new window

0
 
LVL 5

Expert Comment

by:Cvijo123
ID: 22681805

btw. one time i found this article to export data for excel file.

From excel u can do anything

http://weblogs.sqlteam.com/mladenp/archive/2006/07/25/10771.aspx
0
 
LVL 5

Accepted Solution

by:
Cvijo123 earned 500 total points
ID: 22681895
or look at this solution .. same using BCP but inside SP

http://www.experts-exchange.com/Microsoft/Development/MS-SQL-Server/Q_22613323.html
0

Featured Post

What Security Threats Are You Missing?

Enhance your security with threat intelligence from the web. Get trending threat insights on hackers, exploits, and suspicious IP addresses delivered to your inbox with our free Cyber Daily.

Join & Write a Comment

In SQL Server, when rows are selected from a table, does it retrieve data in the order in which it is inserted?  Many believe this is the case. Let us try to examine for ourselves with an example. To get started, use the following script, wh…
In this article I will describe the Copy Database Wizard method as one possible migration process and I will add the extra tasks needed for an upgrade when and where is applied so it will cover all.
Get a first impression of how PRTG looks and learn how it works.   This video is a short introduction to PRTG, as an initial overview or as a quick start for new PRTG users.
This video demonstrates how to create an example email signature rule for a department in a company using CodeTwo Exchange Rules. The signature will be inserted beneath users' latest emails in conversations and will be displayed in users' Sent Items…

706 members asked questions and received personalized solutions in the past 7 days.

Join the community of 500,000 technology professionals and ask your questions.

Join & Ask a Question

Need Help in Real-Time?

Connect with top rated Experts

19 Experts available now in Live!

Get 1:1 Help Now