Camilo Gonzalez wrote:
> 
> The @model array is composed of condo unit numbers, 301-627ish. The values
> may later be names so I'm treating them as strings.

ok, now we're getting somewhere.  i'm posting your original code here:

> I'm trying to construct a hash of hashes from data sent to a script from a
> form. I've already parsed the arrays @data and @model to the point I want
> them. This is the code that fails me:
>  
>               $i=0;
>           for $fields(split /&/, @data) {         
>               ($key, $value) = split /=/, $fields;
>               $bigData{$model[$i]}{$key} = "$value";
>               $i++;
>           }
>  
> It won't print out @data or @model from anywhere inside the for loop and
> won't print out specific dereferencing like "$bigData{307}{Price}. 

so what you need is a way to associate a group of key-value pairs with
each unit number.  maybe something like this:

%data = (
  307 => { key1 => value1, key2 => value2, key3 => value3 },
  308 => { key1 => value4, key2 => value5, key3 => value6 },
  309 => { key1 => value7, key2 => value8, key3 => value9 },
  310 => { key1 => value10, key2 => value11, key3 => value12 }
);

so the next questions would be:
1)  are the individual units submitting the data independently, or do
all units have the same data?
2)  is it possible that you could have more than one value for the same
key?

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

Reply via email to