日期:2014-05-16 浏览次数:20707 次
select co.id,co.user_id,co.buyer_fullname,co.buyer_address_1,co.buyer_address_2,co.item_code,co.quantity,co.notes_to_yourself,co.batch_id,co.sales_record_number,co.buyer_city,co.buyer_state,co.buyer_zip,co.buyer_country,co.TRANSACTION_ID,co.ORDER_ID from confirmed_order co inner join batch_parameters bp on co.batch_id=bp.batch_id and bp.loading_type='READY_TO_SHIP' and bp.status='C' and not exists(select id from op where op.co_id=co.id)where (co.transaction_id='' or co.order_id='') and co.id>1234560;
select co.id,co.user_id,co.buyer_fullname,co.buyer_address_1,co.buyer_address_2,co.item_code,co.quantity,co.notes_to_yourself,co.batch_id,co.sales_record_number,co.buyer_city,co.buyer_state,co.buyer_zip,co.buyer_country,co.TRANSACTION_ID,co.ORDER_ID from confirmed_order co inner join batch_parameters bp on co.batch_id=bp.batch_id and bp.loading_type='READY_TO_SHIP' and bp.status='C' and not exists(select id from op where op.co_id=co.id)where (co.transaction_id='' or co.order_id='') and co.id>0;