Hi,

I'm using associative arrays in ASP 0.16, but it doesn't work... I have
taken the same portion of code in a .pl file and execute it, it works...

Do associative arrays work with modperl ? Could anybody help me ?

An extract of my program:
%toto = ( "001" => 1, "002" => 2, "003" => 3 );
%tato = ( "004"=> 4, "002"=> 5, "005"=> 6 );
$rech = {};
$nb = 2;
for $mot (keys %toto) { $rech{$mot} = 1; }
for $mot (keys %tato) { if (defined $rech{$mot}) { $rech{$mot}++; } }
$recherche = "";
for $mot (keys %rech) { if ($rech{$mot}==$nb) {  $recherche .=
"'$mot',"; } }
chop($recherche);

$recherche equals "'002'" with single perl programming
$recherche equals "" with ASP programming

Thanks in advance...
--
Cedric Avena
WAW - Web At Work - Tel: +33 (0)491 812 145
mailto:[EMAIL PROTECTED] - http://www.waw.com

Reply via email to