In my situation I have a string like so:
my $string = '20050516'; and I want to rearrange it to look like: 05162005, so I tried: my $newstring = substr($string,0,8).substr($string,0,4).substr($string,8,0); But my problem is: it's leaving 2005 in the beginning of the string to look like 200505162005 when all I need is 05162005 Any ideas? thx Derek B. Smith OhioHealth IT UNIX / TSM / EDM Teams 614-566-4145 -- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>