I have the following as my data inside a package:

my $dataBlock = {       isInsertable            => $isInsertable,
                                fields          => undef,
                                requiredFields          => undef,
                                selectionFields         => undef,
                                returnFields            => undef };

How do I go about storing a list as the value of the $dataBlock->{'fields'}
key?

I'd like something like the following to work:

sub setFields
 {
    my ($inBlock, @fieldList) = @_;

    foreach my $i (@fieldList)
    {
       push($inBlock->{'fields'}, $i);
    }

    return $inBlock;
 }

I understand it won't because $inBlock->{'fields'} is not an array...  Any
help would is appreciated.

TIA,

EllioT


-- 
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]

Reply via email to