I have the following scenario:
Recipe Table
---------------------
id
name
preparation mode
category
Ingredient Table
--------------------------
id
name
Ingredient_receive table
--------------------------------------
id
id_receita
id_ingrediente
I want to make a select that brings the recipes with their ingredients according to the ingredients that I inform.
Eg: select recipes that contain flour, egg and sugar (I want you to bring recipes that have only those 3 ingredients, if the recipe has any other ingredients, I do not want it to appear)
Assuming that a carrot cake only has these 3 ingredients
I do not want you to bring it like this:
1 | Carrot cake | preparation mode: blablabla | Category: Sweets | flour
1 | Carrot cake | preparation mode: blablabla | Category: Sweets | egg
1 | Carrot cake | preparation mode: blablabla | Category: Sweets | sugar
I want you to bring it like this (All on the same line):
1 | Carrot cake | preparation mode: blablabla | Category: Sweets | flour | egg | sugar
Database: Mysql
Can you help me? Thank you.