DEV Community

Dimitrios Desyllas
Dimitrios Desyllas

Posted on

How I can get products using multiple skus?

As I ask upon:
https://magento.stackexchange.com/q/369468/113388

I have a list of skus:

  $skus = ['24-MB01','24-MB04','24-UG01'];
Enter fullscreen mode Exit fullscreen mode

And based on these I want to retrieve the products:

/**
 * @var \Magento\Catalog\Model\ProductRepository
 */
private $productRepository
...
$this->productRepository->addFieldToFilter('sku',$skus);
Enter fullscreen mode Exit fullscreen mode

But I cannot get them. Do you have any idea on how I can do this?

Top comments (0)

Image of Docusign

🛠️ Bring your solution into Docusign. Reach over 1.6M customers.

Docusign is now extensible. Overcome challenges with disconnected products and inaccessible data by bringing your solutions into Docusign and publishing to 1.6M customers in the App Center.

Learn more