SSIS Flat File Destination prevent text quoting in fields with no data
-
29-05-2021 - |
Question
I'm creating an exported CSV file in SSIS (2008) in which text fields need to be surrounded in quotes. Easy enough. But my requirments say that if there is no data in a text field, there should be no quotes either. But SSIS will put two double quotes in. So instead of this, which SSIS provides:
"field 1 text","","","field 4 text"
I need this:
"field 1 text",,,"field 4 text"
I don't see a way to do this in the SSIS package and would prefer not to remove them in my application after the file has been created. Anyone know if this can be done inside SSIS?
Solution
So I guess I'm just stuck with opening the file created by SSIS in code and making the edits there. That's the direction I went and while it took a while it works. I guess sometimes I expect SSIS to do more of these things for me than I ought to.
Also notable is that I also had to add my header and footer records programmatically, didn't see an easy way to do it in SSIS.