I have table with objects
uuid | name |
---|---|
98665e5a-e1cb-4bf7-93fa-a8d13983f358 | object |
and another table with information about enabled this object and another object together
uuid_from_table_upper | enabled | uuid_another_object |
---|---|---|
98665e5a-e1cb-4bf7-93fa-a8d13983f358 | true | ad5e670a-adac-485b-879e-9448d68a393c |
98665e5a-e1cb-4bf7-93fa-a8d13983f358 | false | a55b021b-ae4b-4373-91ae-87b9f7134862 |
i need a sql query, return object from first table object, who doesn`t have true in second table
SELECT ft.*
FROM first_table ft
JOIN second_table st on ft.uuid = st.uuid_from_table_upper
WHERE
not st.enabled;
i guess needed group by or recursive with