I recently wrote about the ALL operator in T-SQL. It's used to check how a given value compares to a list of values. That list generally comes from a sub-query that returns a single column. While the ALL operator isn't well known, there are also other related operators SOME and ANY.
Instead of returning whether or not all the values in a list meet the logical operation, these return whether any of the values in the list meet the requirement.
I've changed the query that I previous used for ALL, to now use SOME. So instead of working out the oldest order where we can supply all items, it finds the oldest order where we can supply some of the items.