I have 6 files in which 2 files have 53 fields and rest have 49 fields.
I want an output having a common schema of 53 fields THROUGH AB INITIO such that when I process files having 43 fields it comes as blank in the output schema by itself.
How can I achieve this?
How to transform fields in abinitio so as to have common schema in output file?
2k Views Asked by Jinson Fernandez At
1
You can achieve that by simply using the REFORMAT component. Attach the proper record format to each Input File components (in your case, containing either 49 or 53 fields).
Then you can attach the ones with 49 fields directly to a GATHER component. The files having a lesser number of fields you can just attach them to the input of a REFORMAT and connect the REFORMAT output to the GATHER component.
Then in the Transform, you just connect corresponding input/output fields and fill with a constant value ("",0,etc...) the 4 missing ones.