January 3, 2014 at 1:06 am
I am using bcp to insert data into a table. For just one column, i am getting NULL values as character 'NULL'. How can we deal with it ? I was checking in MS site and it gives one -k option which specifies that "empty columns should retain a null value during the operation, rather than have any default values for the columns inserted".
However I'm looking for a solution where the NULL should be treated as NULL value and not 'NULL' string for just one column. Can anyone suggest what to do ?
January 3, 2014 at 7:07 am
I'll try using blank value rather than NULL in txt file.
January 3, 2014 at 11:15 pm
A NULL value in a CSV file is two delimiters with nothing between them. You're not using the actual word 'NULL' in your file are you? Also, do you have a trigger that might be converting a real NULL to the word 'NULL' in that one column?
--Jeff Moden
Change is inevitable... Change for the better is not.
Viewing 3 posts - 1 through 2 (of 2 total)
You must be logged in to reply to this topic. Login to reply