这是数据集里的sql语句 select h.CUSTOMER_PO_NUMBER as 客户PO, h.ORDER_NUMBER as 生产编号, ooot.ORDER_TYPE_NAME as 订单类型, v.ACCOUNT_SHORT_NAME as 客户简称, atts.suit_count as 套数, h.order_status as 订单状态, h.order_progress as 订单进展, h.creation_date as 订单创建日期, h.BOOKED_DATE as 订单受理日期, h.complete_date as 订单完工日期, tv.meaning2 as 省区 from APPS.OMS_OE_ORDER_HEADERS h, APPS.OMS_OE_ORDER_TYPES ooot, apps.cux_om_order_headers_v v, APPS.OMS_OE_ORDER_HEADER_ATTS atts, apps.mdm_cust_territory_solutions_v tv where 1=1 ${if(len(订单类型)==0,"","and ooot.ORDER_TYPE_NAME='"+订单类型+"'")} ${if(len(订单编号)==0,"","and h.ORDER_NUMBER='"+订单编号+"'")} ${if(len(po)==0,"","and h.CUSTOMER_PO_NUMBER='"+po+"'")} ${if(len(客户简称)==0,"","and v.ACCOUNT_SHORT_NAME='"+客户简称+"'")} ${if(len(sq)==0,"","and tv.meaning2 in ('"+sq+"')")} and v.order_type_id=ooot.order_type_id and ooot.order_type_id=h.order_type_id and h.header_id=atts.header_id and atts.header_id=v.header_id group by h.CUSTOMER_PO_NUMBER , h.ORDER_NUMBER , ooot.ORDER_TYPE_NAME , v.ACCOUNT_SHORT_NAME, atts.suit_count, h.order_status, h.order_progress, h.creation_date, h.BOOKED_DATE, h.complete_date, tv.meaning2 |