Link to home
Start Free TrialLog in
Avatar of tthompsonsql
tthompsonsqlFlag for United States of America

asked on

BCP Invalid Character value for cast specification error

I am getting the 'Invalid Character value for Cast Specification' error when I try to bcp a text file in. I am pretty certain that its because of the '/' in the date. Is there a command that I can run to eliminate those from the text doc and replace with another character that will copy?
ASKER CERTIFIED SOLUTION
Avatar of EugeneZ
EugeneZ
Flag of United States of America image

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of tthompsonsql

ASKER

Actually the date is only the month/day i.e. 1/15, but i want code that can run in my .bat file that will replace the / with a character that bcp will allow to be uploaded
so  is the fix not for your case?

pls, post some sample code where you have /
I'm going to replace the '/' with '-' and see if your above solution will work then. thanks.