Removing multiple header lines from CSV file
I have a IDOC to CSV file scenario in PI, where multiple IDOCs for a particular Vendor gets converted into a single CSV file. Now as per the requirement, we need to generate a header line in the CSV file.
I have developed it and currently header line is generating in the file but the problem is, each and every time a IDOCs sent to PI, the header generation logic gets triggered and at end in the final CSV file, multiple header lines are populating instead of once.
Kindly suggest to solve the issue.
Do let me know if you require any further information on the same.
I think there is no validation available to check if the file already exists on the server then don't need of header line and if not need to use header line in the file at the channel level.
I think we can go for IDOC packaging where you can generate file for multiple idoc's. Check out the below blog for the same.