Mombu the Programming Forum sponsored links

Go Back   Mombu the Programming Forum > Programming > problem with BCP: skip the first data row
User Name
Password
REGISTER NOW! Mark Forums Read

sponsored links


Reply
 
1 13th June 00:43
henry j.
External User
 
Posts: 1
Default problem with BCP: skip the first data row


I found out that in our application the first data rows of some data
files have been cut off when the data files are uploaded into sybase
(v 12.5 on solaris).

I use the -F 2 option to skip the header row. However the 2nd row,
which is the first data row, is skipped as well. If I use the -F 1
option, the first data row is skipped as well. I tried all different
approaches, including inserting some blank rows between the header and
the first data row, no luck. The first data row is still skipped.

If I remove the header row, and use -F 1, it works fine.

The problem data file has 67 columns, not sure if this causes the
problem to occur. But my data files with far less columns work fine
where the -F 2 option just skips the header row as expected.

Does any one know if this is a bug? Any info is appreciated. Thanks
a lot!

The version of the BCP is:


Sybase CTBCP Utility/12.5/P-EBF11057 ESD#11/DRV.12.5.0.6/SPARC/Solaris
2.8/BUILD125-029/OPT/Thu Apr 17 00:46:17 2003
  Reply With Quote


  sponsored links


2 13th June 00:44
bret
External User
 
Posts: 1
Default problem with BCP: skip the first data row


Does the header row have the correct number of column terminators, and
the same line terminator as the data rows?
  Reply With Quote
3 13th June 00:44
keith
External User
 
Posts: 1
Default problem with BCP: skip the first data row


That was my thought too; did the file come from a WinDOS machine or
similar, and you neglected to run dos2unix on it?

Can you verify the newline character w/ the "od" command or "sed -n
1,3l" or somesuch?

Keith
  Reply With Quote


  sponsored links


Reply


Thread Tools
Display Modes




Copyright 2006 SmartyDevil.com - Dies Mies Jeschet Boenedoesef Douvema Enitemaus -
666