Unexpected EOF encountered in BCP Unexpected EOF encountered in BCP sql sql

Unexpected EOF encountered in BCP


If the file is tab-delimited then the command line flag for the column separator should be -t\t -t,


Just an FYI that I encountered this same exact error and it turned out that my destination table contained one extra column than the DAT file!


"Unexpected EOF" normally means means the column or row terminator is not what you expectThat is, your command line arguments for these do match the file

Typical causes:

  • Unix vs Windows line endings
  • Text data containing your column delimiter (comma in actual data)
  • Or a mix of the two.

SSMS should have nothing to do with it: it's the format (expected vs actual) that matters