2

im importing a large csv programmatically and i want to save product length width height and didn't found any post related to this, so:

I tried to:

$product->setCustomAttribute('width',(int)$data[22]);
$product->setCustomAttribute('ts_dimensions_width',(int)$data[22]);

from product attributes

$product->setData('lenght',$data[21]);

Any of these more logical ways didn't work. any ideas? thanks!

0

Turned out to discover that the code was right! but in configuration: Stores->Product Attributes, we have to set them to GLOBAL.

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.