ค้นหาจำนวนสินค้าทั้งหมดที่สั่งซื้อก่อน 17-03-2018 07:13:53 น.
Find the total amount of products ordered before 2018-03-17 07:13:53.
df_customer_orders = pd.DataFrame(columns=['order_id', 'order_date']); df_order_items = pd.DataFrame(columns=['order_quantity', 'order_id'])
df_order_items[df_customer_orders[pd.to_datetime(df_customer_orders['order_date']) < '2018-03-17 07:13:53']['order_id'].isin(df_order_items['order_id'])]['order_quantity'].sum()