[2 days left] What’s wrong with your cloud strategy? Learn why multicloud solutions matter with Nimble Storage.Register Now

x
?
Solved

BCP errors

Posted on 2006-07-19
8
Medium Priority
?
682 Views
Last Modified: 2012-06-27
I have  sqlserver database,and have to update this table with daily report.txt file.  i am using bcp tool to append the table, i ame having problome. the command is  
bcp master.dbo.pop IN  C:\log_task.txt -c -T -r -U -P
and the error is :
 sqlstate= s1000, nativeError. ODBC sql server Diriver unexpected EOF encountered in bcp data file.

is bcp is the best tool to be used or there are alternative procedure that can be ran from sql Server itself.

Thank you
0
Comment
Question by:huda12
[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
8 Comments
 
LVL 75

Expert Comment

by:Aneesh Retnakaran
ID: 17137335
Post few lines of you text
0
 
LVL 75

Accepted Solution

by:
Aneesh Retnakaran earned 172 total points
ID: 17137339
bcp master.dbo.pop IN  C:\log_task.txt -n -T
0
 
LVL 3

Assisted Solution

by:chhapia_chintak
chhapia_chintak earned 164 total points
ID: 17137361
It can be a case that datatype of field you are importing does not match to the fields in the destination table(data type mismatch ) or An identity column had been added as the first column in the table and BCP is trying to put a value into it.

Or if not above case then Below URL may help:
http://support.microsoft.com/default.aspx/kb/271344

You can aslo use DTS package instad of BCP to import data.


0
 
LVL 11

Assisted Solution

by:deroby
deroby earned 164 total points
ID: 17138207
Most likely your field-separator is wrong, or (in the worst case), some fields may contain the field-separator causing them to get split up...
Like  aneeshattingal asked, post like the first 5 lines AND the last 5 lines of c:\log_task.txt here... just to get an idea.
0

Featured Post

Hire Technology Freelancers with Gigs

Work with freelancers specializing in everything from database administration to programming, who have proven themselves as experts in their field. Hire the best, collaborate easily, pay securely, and get projects done right.

Question has a verified solution.

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

Ready to get certified? Check out some courses that help you prepare for third-party exams.
This month, Experts Exchange sat down with resident SQL expert, Jim Horn, for an in-depth look into the makings of a successful career in SQL.
This video shows how to set up a shell script to accept a positional parameter when called, pass that to a SQL script, accept the output from the statement back and then manipulate it in the Shell.
Via a live example, show how to backup a database, simulate a failure backup the tail of the database transaction log and perform the restore.

656 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