Enterprise Asset Management - EBS (MOSC)

MOSC Banner

how to allocate materials when create a new request material with EAM_PROCESS_WO_PUB API?

edited Mar 4, 2015 11:43AM in Enterprise Asset Management - EBS (MOSC) 8 commentsAnswered ✓

Hi experts

I´m using EAM_PROCESS_WO_PUB API , to create work orders, update/create operations and create request material to work orders, all this routines works fine, but I also need allocate materials when a new material request is inserted.

If inserting a request using web interface or forms it is allocating correctly. the EBS it's parametrized to do this.

Here is the function that calls EAM_PROCESS_WO_PUB API,

OBS: the work order status is already RELEASED.

FUNCTION create_wip_req_operation(
    p_inventory_item_id IN NUMBER,
    p_required_quantity IN NUMBER,
    p_operation_seq_num IN NUMBER,
    p_wip_entity_id     IN NUMBER )
  RETURN NUMBER
IS
  g_eam_wo_relations_tbl0 eam_process_wo_pub.eam_wo_relations_tbl_type;
  g_eam_wo_relations_rec eam_process_wo_pub.eam_wo_relations_rec_type;
  g_eam_op_rec0 eam_process_wo_pub.eam_op_rec_type;
  g_eam_op_rec1 eam_process_wo_pub.eam_op_rec_type;
  g_eam_op_network_rec0 eam_process_wo_pub.eam_op_network_rec_type;
  g_eam_op_network_rec1 eam_process_wo_pub.eam_op_network_rec_type;
  g_eam_mat_req_rec0 eam_process_wo_pub.eam_mat_req_rec_type;
  g_eam_mat_req_rec1 eam_process_wo_pub.eam_mat_req_rec_type;
  g_eam_di_rec0 eam_process_wo_pub.eam_direct_items_rec_type;
  g_eam_di_rec1 eam_process_wo_pub.eam_direct_items_rec_type;
  g_eam_res_rec0 eam_process_wo_pub.eam_res_rec_type;
  g_eam_res_rec1 eam_process_wo_pub.eam_res_rec_type;
  g_eam_res_inst_rec0 eam_process_wo_pub.eam_res_inst_rec_type;
  g_eam_res_inst_rec1 eam_process_wo_pub.eam_res_inst_rec_type;
  g_eam_op_tbl0 EAM_PROCESS_WO_PUB.eam_op_tbl_type;
  g_eam_op_tbl1 EAM_PROCESS_WO_PUB.eam_op_tbl_type;
  g_eam_op_network_tbl0 EAM_PROCESS_WO_PUB.eam_op_network_tbl_type;
  g_eam_res_tbl0 EAM_PROCESS_WO_PUB.eam_res_tbl_type;
  g_eam_res_inst_tbl0 EAM_PROCESS_WO_PUB.eam_res_inst_tbl_type;
  g_eam_sub_res_tbl0 EAM_PROCESS_WO_PUB.eam_sub_res_tbl_type;
  g_eam_res_usage_tbl0 EAM_PROCESS_WO_PUB.eam_res_usage_tbl_type;
  g_eam_mat_req_tbl0 EAM_PROCESS_WO_PUB.eam_mat_req_tbl_type;
  g_eam_di_tbl0 EAM_PROCESS_WO_PUB.eam_direct_items_tbl_type;
  g_out_eam_wo_relations_tbl eam_process_wo_pub.eam_wo_relations_tbl_type;
  g_out_eam_wo_rec eam_process_wo_pub.eam_wo_rec_type;
  g_out_eam_wo_tbl eam_process_wo_pub.eam_wo_tbl_type;
  g_out_eam_op_tbl EAM_PROCESS_WO_PUB.eam_op_tbl_type;
  g_out_eam_op_network_tbl EAM_PROCESS_WO_PUB.eam_op_network_tbl_type;
  g_out_eam_res_tbl EAM_PROCESS_WO_PUB.eam_res_tbl_type;
  g_out_eam_res_inst_tbl EAM_PROCESS_WO_PUB.eam_res_inst_tbl_type;
  g_out_eam_sub_res_tbl EAM_PROCESS_WO_PUB.eam_sub_res_tbl_type;
  g_out_eam_res_usage_tbl EAM_PROCESS_WO_PUB.eam_res_usage_tbl_type;
  g_out_eam_mat_req_tbl EAM_PROCESS_WO_PUB.eam_mat_req_tbl_type;
  g_out_eam_di_tbl EAM_PROCESS_WO_PUB.eam_direct_items_tbl_type;
  g_eam_wo_rec1 eam_process_wo_pub.eam_wo_rec_type;
  g_eam_wo_rec2 eam_process_wo_pub.eam_wo_rec_type;
  g_eam_wo_tbl0 eam_process_wo_pub.eam_wo_tbl_type;
  g_eam_wo_res_usg_tbl0 eam_process_wo_pub.eam_res_usage_tbl_type;
  l_return_status VARCHAR2(1);
  l_msg_count     NUMBER;
  l_msg_data      VARCHAR2(32000);
  l_msg_index    
Tagged:

Howdy, Stranger!

Log In

To view full details, sign in to My Oracle Support Community.

Register

Don't have a My Oracle Support Community account? Click here to get started.

Category Leaderboard

Top contributors this month

New to My Oracle Support Community? Visit our Welcome Center

MOSC Help Center