I had a text file(comma seperated values) which contains as below
196237,ram,25-May-06,ram.kiran@xyz.com,204183,Pavan,4-Jun-07,Pavan.Desai@xyz.com,237107,ram Chandra,15-Mar-10,ram.krishna@xyz.com ,237547,Ravi,6-Apr-10,ravi.gupta@xyz.com,245281,Dheeraj,6-Dec-10,Dheeraj_Turupu@xyz.com,257599,Venkata Maniteja,5-Dec-11,Venkat.alaga@xyz.com
I require the text exactly as below(new line has to be inserted after the mail id i.e., every 4th field) as below
after running the script
196237,ram,25-May-06,ram.kiran@xyz.com,
204183,Pavan,4-Jun-07,Pavan.Desai@xyz.com,
237107,ram Chandra,15-Mar-10,ram.krishna@xyz.com ,
237547,Ravi,6-Apr-10,ravi.gupta@xyz.com,
245281,Dheeraj,6-Dec-10,Dheeraj_Turupu@xyz.com,
257599,Venkata Maniteja,5-Dec-11,Venkat.alaga@xyz.com
How to write a perl script to format the raw text file as mentioned above ?
Could you please provide your suggestions and ideas on the above ?
Thanks in advance....
Regards,
Giri