Home Forums SQL Server 2005 T-SQL (SS2K5) trying to export to .CSV with comma delimited AND double-quotes RE: trying to export to .CSV with comma delimited AND double-quotes

  • cmcc (11/1/2012)


    🙁

    Didn't work.

    Getting this

    ...is too long. Maximum length is 128.

    I use a view for the data, which is short enough.

    It's getting the column names output that is causing me problems.

    I'd use SSIS but I don't have time - I've been fiddling with this problem in SSIS for six weeks now, off and on, and keep tripping over one SSIS issue after another.

    At least the BCP error makes sense to me.

    In SSIS I have to change the file names - they have to be the date the package is run or the date from a parameter I have to pass in. This is a piece of cake from a parameter in a stored procedure but is taking a while to work through in SSIS.

    i.e. I haven't gotten it to work yet.

    ARGH!!!!

    Haven't seen you posting these questions in the SSIS forum 🙂

    You could also, perhaps (if the columns are static), create a text file somewhere which contains only the column headings.

    Then, after your BCP has run, use a simple DOS Copy to append one file to the other.

    If you haven't even tried to resolve your issue, please don't expect the hard-working volunteers here to waste their time providing links to answers which you could easily have found yourself.