2

Change configurable product SKU programmatically into associated product and custom option are removed using this code.

$_product = $this->_objectManager->create('\Magento\Catalog\Model\Product')->loadByAttribute('sku', $old_sku);
$_product->setSku($new_sku)->save();

Your Answer

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

Browse other questions tagged or ask your own question.