http://www.perlmonks.org?node_id=999305

Thomas Kennll has asked for the wisdom of the Perl Monks concerning the following question:

Hi

I wanted to increase all records field size in a file..

for eg) if i have a file like rij1
bash-2.03$ cat rij1 DSE 1232123456 ABCDEF96DS0 + 20100722 20120827KJHLK LKEDX + 05 +8305574 IAC 8 S73 + + WERTYU bash-2.03$

Currently the 2nd field has 11 characters, ie 1232123456

I want to increase the character size to 50, ie append the remaining with spaces.. result "1232123456(39 spaces) --> Total count should be 50 for this field " can someone help here..

Update: Thank You all for your help!! :)

I have a problem as the field are not necessarily field seperated.. If I could insert 39 spaces from postion 15 or from 15th character on all records will do.. Can anyone help.. Thanks again!!