I'm having a bit of trouble with conceptualizing this problem. I'm pretty new to mysql and I'm working on my first large-scale project.
Here's what I'm trying to understand. I have a table that keeps track of all orders. Then, each person can add one of those orders to their table. When that person queries the orders table, I don't want them to be able to see the ones that they have already put in their table. It's okay if someone else can see an order that Joe has taken, just not Joe.
Ex:
all_orders (order_ID, type, description)
1, plain, etc.
2, decorated, etc.
3, filled, etc.
4, outlined, etc.
joes_orders (order_ID, type, description, destination)
1, plain, etc., Charles Place
3, filled, etc., Apple Woods
When Joe queries all orders, I only want him to see:
2, decored, etc.
4, outlined, etc.
However, I can't seem to understand this "anti" join situation.
Here's what I'm trying to understand. I have a table that keeps track of all orders. Then, each person can add one of those orders to their table. When that person queries the orders table, I don't want them to be able to see the ones that they have already put in their table. It's okay if someone else can see an order that Joe has taken, just not Joe.
Ex:
all_orders (order_ID, type, description)
1, plain, etc.
2, decorated, etc.
3, filled, etc.
4, outlined, etc.
joes_orders (order_ID, type, description, destination)
1, plain, etc., Charles Place
3, filled, etc., Apple Woods
When Joe queries all orders, I only want him to see:
2, decored, etc.
4, outlined, etc.
However, I can't seem to understand this "anti" join situation.