I urgently need to export all the combinations of the products of my Prestashop store to pass them to the new store that I am doing, but I cannot make the SQL query so that the .csv file is exported correctly to be able to import them in the new store.
I need the query to be like Prestashop does, so that when importing it, it doesn't fail me.
Attached photo of how is the file created by Prestashop.
Thank you very much in advance.
Have you developed a module or a script for it?
In the official documentation of Prestashop explains how to do query:
DB class and DBQuery class
I'll give you an example of how I do a sql query:
In your case you have to use the ps_product table, ps_product_attribute among others.
I advise you to use DBeaver or Navicat to do the sql query and when you get what you want with all the columns you need, you use it in Prestashop.
If you have part of the sql query already done but it gives you errors, you can share it and we can help you better.