Ok, if I do that on the products side:
SELECT a.`id_product`, b.`name` AS `name`, `reference`, a.`price` AS `price`, sa.`active` AS `active` , shop.`name` AS `shopname`, a.`id_shop_default`, m.`name` AS `name_manufacturer`, s.`name` AS `name_supplier`, image_shop.`id_image` AS `id_image`, cl.`name` AS `name_category`, sa.`price`, 0 AS `price_final`, a.`is_virtual`, pd.`nb_downloadable`, sav.`quantity` AS `sav_quantity`, sa.`active`, IF(sav.`quantity`<=0, 1, 0) AS `badge_danger` FROM `tb_product` a LEFT JOIN `tb_product_lang` b ON (b.`id_product` = a.`id_product` AND b.`id_lang` = 1 AND b.`id_shop` = 1) LEFT JOIN `tb_stock_available` sav ON (sav.`id_product` = a.`id_product` AND sav.`id_product_attribute` = 0 AND sav.id_shop = 1 AND sav.id_shop_group = 0 ) JOIN `tb_product_shop` sa ON (a.`id_product` = sa.`id_product` AND sa.id_shop = a.id_shop_default) LEFT JOIN `tb_category_lang` cl ON (sa.`id_category_default` = cl.`id_category` AND b.`id_lang` = cl.`id_lang` AND cl.id_shop = a.id_shop_default) LEFT JOIN `tb_shop` shop ON (shop.id_shop = a.id_shop_default) LEFT JOIN `tb_image_shop` image_shop ON (image_shop.`id_product` = a.`id_product` AND image_shop.`cover` = 1 AND image_shop.id_shop = a.id_shop_default) LEFT JOIN `tb_image` i ON (i.`id_image` = image_shop.`id_image`) LEFT JOIN `tb_manufacturer` m ON (m.`id_manufacturer` = a.`id_manufacturer`) LEFT JOIN `tb_supplier` s ON (s.`id_supplier` = a.`id_supplier`) LEFT JOIN `tb_product_download` pd ON (pd.`id_product` = a.`id_product` AND pd.`active` = 1) WHERE 1 ORDER BY a.`id_product` ASC LIMIT 0, 50
I get answer:
MySQL said:
#1046 - No database selected
So there is defently somthing with the database.