I wish to convert this file into a .xls file with C1 (all the text under it, included) as Column A, C2 as Column B and C3 as Column C, in the spreadsheet
Example : In Column A, we must have abc,xyx ; pqr ; egf,uvw a in Row 1,2,3 respectively alongwith their respective values in for C2 and C3 in columns B and C respectively
I can't see <TAB>s, just spaces; should there be <TAB> field delimiters, why don't you replace those by semicolons and read that file in as a .csv file?
You ask us to note spaces and tabs, but you didn't use CODE tags (which are required for us to be able to distinguish tabs and multiple spaces from single spaces). You got an email message and an infraction explaining how to use CODE tags, and Corona688 edited your message to add CODE tags for you. You then edited your post again throwing away the CODE tags Corona688 was nice enough to add for you. I have added them for you again. Please review the following before editing any more of your existing posts or creating any new posts:
Then note that there are no tab characters at all in the first post in this thread and note that the spacing in the 1st column of the input you say you have does not match the spacing in your description of the output that follows (is removing the space after the comma accidental or intentional).
You haven't told us what operating system or shell you're using, and some of the things you're trying to do might be easier on some operating systems. Some versions of perl with some add-on packages can produce Microsoft proprietary Excel files, but, as RudiC suggested, you can produce a character separated values file using a semicolon as the field separator and Excel will be able to load your spreadsheet from that file. For example, you could try something like: