The slow way that works:

            ->setData($code , null)

I've seen:

            ->addAttributeUpdate($code, null , $storeId);

This however deletes the default value as well. (possible bug ?)

Other examples I have seen are raw mysql delete queries.

I though that this would be something native to Magento.

Any thoughts on this?


Try it like this:

    array($productId),  //array with product ids - works with multiple ids at the same time
    array($code=>null), //attributes to update - can update multiple attributes in one call 
    $storeId, //store to update. 0 = default values.
  • This works for updating a store value to a value, but not for setting it to use default – Danny Dev Nz Jul 7 '14 at 7:14

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.