Laravel - Get records from one table that doesn't exist in another
Hello,
I have 3 tables - orders, items, bills. In the items table I have an 'order_id' column that connects item with a specific order. Each item from the items table can be linked to the bills table, where there is a column 'item_id'. Now I would like to retrieve all orders that have an item in the items table, but only if that item's id does not exist in the bills table. I tried something like this to start with :