[plug] Perl Question

Arie Hol arie99 at ozemail.com.au
Tue May 13 14:09:50 WST 2003


At 01:51 PM 13-05-2003 +0800, you wrote:
>Hi all, 
>
>I have a comma-delimited text file containing records, with one line per
>record.  The fields are seperated by commas 
>
>For example, one line from the text file is: 
>
>543,XB5435,0000043,ONSHORE SYSTEM (OS),CLD,Drawing,5/11/95,CX453 
>
>What I want to do is to get each of these data items into a seperate
>variable so that I can then output each field in the required manner 
>


Add a line line that looks something  like this :

($a, $b, $c, $d, $e, $f, $g, $h) = split(/,/, $input_string);

# do something with $a, $b, $c, $d, $e, $f, $g and $h

HTH

Regards Arie

>--------------------------------------------<

For the concert of life, nobody has a program.

>--------------------------------------------<



More information about the plug mailing list