When I preview my BIML, this is how my columns are defined:
<FlatFileFormat Name="(FFF) MyFixedWidthFlatFile" CodePage="1252" FlatFileType="FixedWidth" RowDelimiter="" IsUnicode="false" TextQualifier="_x003C_none_x003E_">
<Columns>
<Column Name="HEADER" DataType="Binary" Length="2" Delimiter="" TextQualified="false" ColumnType="FixedWidth" MaximumWidth="2"></Column>
<Column Name="DESCRIPT" DataType="AnsiString" Length="30" Delimiter="" TextQualified="false" ColumnType="FixedWidth" MaximumWidth="30"></Column>
The package is generated succesfully, however, the OutputColumnWidth in the Flat File Connection is not set for the binary columns.
The String columns are correct.
What am I missing?
Thank you!
So I did a thing. The following code edits the DTSX file to add the missing attributes. BEWARE: if you intend to reuse this code, it will change your package on save, not on package generation. If you're not comfortable with that, wrap it inside an EXE. Also, it could break your package so be sure you can generate it again or that you have a backup. The package and the BIML file should be in the same directory.