Ravi,
I agree with Linus. It can be done, but it is a lot of tedious data step programming.
If you have to do it, here are some things that you need to learn about:.
The biggest is pointer control in the INPUT statement. It allows you to align the pointer with the data that you want to use.
You may also need to do a lot with the various index functions (INDEXC, etc.) and SUBSTR.
Good luck.