SELECT DISTINCT a.business_unit , a.order_no FROM ps_cp_opt_hdr a , PS_ORD_SCHEDULE b , ps_ord_line c WHERE ((a.mfg_process_flg IN ('B','E') AND a.production_id = ' ') OR a.mfg_process_flg = 'C') AND a.business_unit = b.business_unit AND a.business_unit = c.business_unit AND b.business_unit = c.business_unit AND a.order_no = b.order_no AND a.order_no = c.order_no AND b.order_no = c.order_no AND a.order_int_line_no = b.order_int_line_no AND a.order_int_line_no = c.order_int_line_no AND b.order_int_line_no = c.order_int_line_no AND b.demand_sent = 'Y' AND b.in_fulfill_state <> '10' AND b.drop_ship_flag = 'N' AND a.cp_mode = 'S' AND c.ord_line_status = 'O'
|