题解 | #确定哪些订单购买了 prod_id 为 BR01 的产品(二)#
确定哪些订单购买了 prod_id 为 BR01 的产品(二)
http://www.nowcoder.com/practice/999aa31a9a504c60baa088d90d82e64d
select Orders.cust_id,Orders.order_date from OrderItems,Orders where OrderItems.order_num = Orders.order_num and OrderItems.prod_id="BR01" order by Orders.order_date 两表进行关联,关联条件为order_num,然后添加条件prod_id="BR01",再进行排序