Suppress column name output in BCP

  • I'm sure this is just a command line switch, but I'm unable to find it in the command line help or on BOL... I am running BCP out for an ETL operation, and the receiving app expects the data without headers. How do I suppress the header row with column names in it?

    Thx,

    tim

  • Are you sure we're talking BCP 'cause BCP doesn't output column headers and can't be made to do so... it requires a UNION in a proc to output column headers in BCP. Don't know of any switch option to force it to include column headers, either.

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

  • Thanks Jeff, you are correct - the file I was chasing down was actually not generated using bcp at all but another process. That'll teach me to to assume, eh?

  • It that case... might be OSQL... THAT does have such a set of switches... if memory serves, "-h-1" (no spaces, no quotes) would be the switch you're looking for.

    --Jeff Moden


    RBAR is pronounced "ree-bar" and is a "Modenism" for Row-By-Agonizing-Row.
    First step towards the paradigm shift of writing Set Based code:
    ________Stop thinking about what you want to do to a ROW... think, instead, of what you want to do to a COLUMN.

    Change is inevitable... Change for the better is not.


    Helpful Links:
    How to post code problems
    How to Post Performance Problems
    Create a Tally Function (fnTally)

Viewing 4 posts - 1 through 3 (of 3 total)

You must be logged in to reply to this topic. Login to reply