?
Solved

bcp copy

Posted on 2007-11-13
3
Medium Priority
?
914 Views
Last Modified: 2008-02-01
I am running SQL Server Management Studio Express 2005.  I am trying to bulk copy the contents of a csv file into a table.  I've opened the command winow and typed in the following:

bcp "Public_data.dbo" in "c:\customer_service_reportcard.csv" -c -q -U"xxxxxx" -P"xxxxxxx"

I get the following error:
SQLState = 08001. NativeError = 2
Error = [Microsoft][SQL Native Client] Named Pipes Provider: Could not open a connection to SQL Server [2]
SQLState = HYT00. NativeError = 0
Error = [Microsoft][SQL Native Client] Login timeout expired
SQLState = 08001. NativeError = 2
Error = [Microsoft][SQL Native Client] An error has occurred while establishing a connection to the server. When connecting to SQL Server 2005, this failure may be caused by the fact that under the default settings SQL Server does not allow remote connections.

SQLServer Management Studio Express is installed on my local PC for development.  Does bcp work with Express?

Any help is appreciated.
0
Comment
Question by:-Dman100-
[X]
Welcome to Experts Exchange

Add your voice to the tech community where 5M+ people just like you are talking about what matters.

  • Help others & share knowledge
  • Earn cash & points
  • Learn & ask questions
  • 2
3 Comments
 
LVL 35

Accepted Solution

by:
David Todd earned 2000 total points
ID: 20277588
Hi,

>>Does bcp work with Express?

Not sure, but generally it doesnt allow remote connections. You will need to enable this.

HTH
  David
0
 

Author Comment

by:-Dman100-
ID: 20277811
I checked the server properties and "allow remote connections to this server" is checked.  Are there any other settings I need to check?

Thanks.
0
 

Author Comment

by:-Dman100-
ID: 20278060
I finally figured it out...for those that come across a similar issue with Express.  You have to specify the server:

bcp DatabaseName.dbo.TableName in c:\filename.csv -c -q -S ServerName\SQLExpress -U xxxxxxx -P xxxxxx -t \t -r \n
0

Featured Post

Free Tool: Port Scanner

Check which ports are open to the outside world. Helps make sure that your firewall rules are working as intended.

One of a set of tools we are providing to everyone as a way of saying thank you for being a part of the community.

Question has a verified solution.

If you are experiencing a similar issue, please ask a related question

INTRODUCTION: While tying your database objects into builds and your enterprise source control system takes a third-party product (like Visual Studio Database Edition or Red-Gate's SQL Source Control), you can achieve some protection using a sing…
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 video we outline the Physical Segments view of NetCrunch network monitor. By following this brief how-to video, you will be able to learn how NetCrunch visualizes your network, how granular is the information collected, as well as where to f…
Michael from AdRem Software explains how to view the most utilized and worst performing nodes in your network, by accessing the Top Charts view in NetCrunch network monitor (https://www.adremsoft.com/). Top Charts is a view in which you can set seve…

771 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