cancel
Showing results for 
Search instead for 
Did you mean: 

want to have a mysql query that does the same thing as magento 2 catelog does

want to have a mysql query that does the same thing as magento 2 catelog does

Hi,

In magento 2 banck end -> products -> catalog is showing all the products with its attributes (including the custom one), i want to have a same mysql query to does the same thing and show it in my databases

Thank you

https://drive.google.com/file/d/0B6UYOu37akeTeGZaSGktMXhldDQ/view?usp=sharing

 

4 REPLIES 4

Re: want to have a mysql query that does the same thing as magento 2 catelog does

Hi @AliveHealth,

 

If you have the collection you can try with to print the raw sql with:

 

$collection->printLogQuery(true);

Or:

 

echo $collection->getSelect()->assemble();

 

 

Re: want to have a mysql query that does the same thing as magento 2 catelog does

Thanks 

Re: want to have a mysql query that does the same thing as magento 2 catelog does

Re: want to have a mysql query that does the same thing as magento 2 catelog does