Question

I am attempting a simple task, to sort the product filter in the admin panel page but I am receiving the error:

Something went wrong with processing the default view and we have restored the filter to its original state.

I have looked at the server logs and the following PHP error is being thrown up when I attempt to sort/filter in the product page of admin panel.

AH01071: Got error 'PHP message: PHP Fatal error: 
Method Magento\\Ui\\TemplateEngine\\Xhtml\\Result::__toString() must not 
throw an exception, 
caught TypeError: Argument 1 passed to 
Magento\\InventorySalesAdminUi\\Model\\GetSalableQuantityDataBySku::
execute() must be of the type string, null given, called in 
/var/www/vhosts/mywebsitehere.com/vendor/magento/module-inventory-sales- 
admin-ui/Ui/Component/Listing/Column/SalableQuantity.php on line 70 in 
/var/www/vhosts/mywebsitehere.com/vendor/magento/module- 
ui/Controller/Adminhtml/Index/Render.php on line 0\n'

This is a clean install of Magento 2.3.0 with only my Magento 1 migrated products added. Using PHP 7.2.15, Plesk Onyx v17.8.11_build1708180301.19 os_CentOS 7.

Any assistance is much appreciated.

Was it helpful?

Solution

SKU should be empty or string. In your case, it is null or not a string.

Run follwoing query will resolve your issue if it is null sku related error:


UPDATE catalog_product_entity SET sku='' WHERE sku IS NULL;

You can check your corrupted sku and fix that.

Licensed under: CC-BY-SA with attribution
Not affiliated with magento.stackexchange
scroll top