Joining Columnar heading from 2 lines

Hi,
Below is the format of a report generated by a custom reporting solution. I opened the report in Notepad++ and junked data and values as in the image below.

I want to convert the values to a PIPE delimited format as below

But there are challenges in getting this as the column heading itself is spread across two lines. There are lot of reports like this covering different subjects. I tried writing a program in Python to get this done. But not able to. Is there any way to handle this?

Thanks,
Ramkrix

Hello ramkrix,

In Unix.com forums we encourage users to add their own efforts which they have put in order to solve their own problems. So kindly do add the same and let us know then. Also samples should be in form of text NOT in form of images of attachments, so please EDIT your question and let us know then.

Thanks,
R. Singh

Hello ramkrix,

Following on from RavinderSingh13's request, the input you paste will also tell us how it is structured, e.g. is it tab seaparated, fixed-width or whatever.

Please paste the input into CODE tags so that is is easier to read and spacing is preserved. Tools such as notepad and variants might make it nice for human reading, but they complicate it when we need to process the data, so a simple copy/paste from the command line is probably best.

Thanks, in advance,
Robin