in reply to Having trouble looping through a data structure
This can make sorting/searching much easier. An AoH in Perl works pretty much like an array of struct in C. And this can be translated into a DB with minimum fuss. Just an idea to consider.my $AoH = [ { 'type' => 'article', 'SKU' => [ 'CDS00013', ], 'InternalSKU' => '179', 'AvailableItems' => ['100',], }, { 'type' => 'article', 'SKU' => [ 'CDS00014', ], 'InternalSKU' => '180', 'AvailableItems' => ['102',], }, { 'type' = 'book', 'SKU' => [ 'CDS00015', ], 'InternalSKU' => '220', 'AvailableItems' => ['103',], }, ];
|
|---|