HI

I would likt to create input files for testing, format is like this

INPUT Format

DISP NUM BYTES Desc
0 4 CODE
4 10 EMP NO
14 3 AGE
17 1 SEX

which will be used for creating flat files ( data in excel file).

OUTPUT file should be continous like

CODE19239625M

like this

Here CODE is the EMPCODE, 192396 is EMPNO, 25 is the AGE and M is SEX.

Can anyone will lead me to write the script ......... PLZ help

Check out the man pages for printf.

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.