A mianowicie jako wynik końcowy chce osiągnąć tablicę, coś na wzór:
Zasadniczo nie ma tutaj żadnego problemu, problem pojawia się z danymi, które mam i które chce wpisać w taką tablicę, a mianowicie:
[id_product_attribute] => 549 [id_product] => 329 [reference] => an880wh-2xl [id_attribute_group] => 1 [attribute_name] => White ) [id_product_attribute] => 549 [id_product] => 329 [reference] => an880wh-2xl [id_attribute_group] => 2 [attribute_name] => 2XL ) [id_product_attribute] => 555 [id_product] => 329 [reference] => an880wh-L [id_attribute_group] => 1 [attribute_name] => White ) [id_product_attribute] => 555 [id_product] => 329 [reference] => an880wh-L [id_attribute_group] => 2 [attribute_name] => L )
jak widzicie częścią wspólną są id_product_attribute oraz reference (dla poszczególnych par) i teraz jeżeli id_attribute_group == 1 to to powinna być wartość klucza mojej nowej tabeli, natomiast jeżeli id_attribute_group == 2 to wartość ta powinna być elementem mojej tablicy, ale.. nie pierwszym lepszym, ale w odpowiednim miejscu, miejsce zależy ile (w tym przypadku będzie rozmiarów).
Qrde zawiesiłem się i nie umie tego przeskoczyć :/
Jakaś pomoc/sugestia?