Hi @ballardw, Thanks a lot for your reply. Actually, I have attached my data, and it's a .txt file. The Random data lines contain headings of the data and all the other text, which can be ignored. The text after "includes.." and below "To be considered:" till a blank (as in the example above) should be the columns headers and I want 2 columns for each. I want this to assign values from the main data, which starts with a number, for example, 123456789123, and the fields under that number belong to it with variables same as the column headers we have mentioned above. So, I want my output to look like this: Column1 ABC_1 ABC_2 DEF_1 DEF_2 GHI_1 GHI_2 JKL_1 JKL_2 XYZ_1 XYZ_2 STU_1 STU_2 LMN_1 LMN_2 123456789123 12 34 56 37 64 73 23455122467 67 43 12 46 87 56 45 78 5674512344 78 45 12 54 32 82 45 36 I hope I have answered all your questions. Please help. @SASKiwi @PaigeMiller: For some reason, my previous post got deleted. This is an example of what my data looks like and what I want. Any help will be greatly appreciated.
... View more