Assuming I have two relations:
Supplier [ID (PK), Name, City, Country] and
Item [ID (PK), Name, Department, Price, Stock, Supplier_ID (FK)]
What would be the easiest way to determine the following statement both in domain and tuple relational calculus: "List the IDs and names of those suppliers, who have delivered at least three different items"?
If, for example, I had to find out if a supplier had delivered only items at a certain price range or if an item was sitting in this or that department, that would't be difficult. It's the "at least three different items" part I can't quite figure out yet. I'm assuming I'd have to juggle around tuples with several different item IDs through AND/OR operators, with some item IDs not equal to other item IDs etc.
Any help with my task would be greatly appreciated!