M9 1a8 8 0 1 0 0 16A8 8 0 0 0 9 1zm. M9 1a8 8 0 1 0 0 16A8 sybase iq binary option 0 0 0 9 1zM8 15.
Since the bcp file is generated by another xml parsing script, I have no control on that to make it generate the fields in the order I want. And now the the order of fields in the bcp file is a little different with the order in the database table. Unexpected EOF encountered in BCP data-file. If possible I would try to get the bcp file reordered, or rebuild the table to match the column order. Alternatively, you can create a temp table with columns in the BCP file order – bcp into the temp table, then select from the temp table into your production table. You can’t BCP into a view, so a view only works if you want to BCP data out of your table in the correct format, so it will be easier to BCP in once the table is rebuilt. Sybase format files can be tricky to use, and I have yet to get them to work to redorder columns.
Use a temp table, or work table for the bcp in, and move the data into your production table from there. Given your data format, the following bcp command line should work. As most of the loader utilities, BCP does not read rows, it just gets a bunch of bytes from the source file, therefore, you have to specify the end line character on the . By the way, please notice the last terminator! Please try to avoid down voting answers that provide a valid alternative solution. Downvotes are intended to be used with incorrect content. I downvoted it because it didn’t help me when I was also stuck with the same issue, and it was marked as “the Answer”, then I just wanted to warn other that this answer was not working, even the same user that posted the question, found the valid answer, which was not related to the answer you wrote but your point is valid!
I upvoted your answers, since they are the better ones. Thanks for contributing an answer to Stack Overflow! Please be sure to answer the question. Provide details and share your research!