Oracle EBS-SQL ,INV-12:检查待定事物处理1.sql

/*未加工物料*/

update inv.mtl_material_transactions_temp

set process_flag='Y',

LOCK_FLAG='N',

TRANSACTION_MODE='3',

ERROR_CODE=NULL;

commit;

然后在应用库存待定事物处理,选择提交

select process_flag,

lock_flag,

transaction_mode,

error_code

from inv.mtl_material_transactions_temp

--------------------------------------------------------------------------

/*未记成本*/

select t.transaction_id,

i.segment1,

t.transaction_group_id,

t.costed_flag,

t.transaction_date

from inv.mtl_material_transactions t,

inv.mtl_system_items i

where t.transaction_date between '&DATE_FROM' and '&DATE_TO'

and t.organization_id=&组织ID

and t.costed_flag='E'

and t.inventory_item_id = i.inventory_item_id

and t.organization_id=i.organization_id

update mtl_material_transactions

set costed_flag = 'N',

request_id = NULL,

transaction_group_id = NULL,

error_code = NULL,

error_explanation = NULL

where costed_flag in ('N','E');

commit;

--------------------------------------------------------------------------

/*待定在制品成本计算*/

update wip_cost_txn_interface

set group_id=null,

transaction_id=null,

request_id=null,

process_status=1

where process_status=3;

pending transaction:

update mtl_transactions_interface

set process_flag=1,

lock_flag=2,

transaction_mode=3,

error_code=null,

where process_flag=3

select * from wip_move_txn_interface

where CREATION_DATE<sysdate -8