Search This Blog

Wednesday, April 19, 2023

API to create Discrete JOB in WIP (WIP Job Order)


DELETE FROM wip_job_schedule_interface;


INSERT INTO wip_job_schedule_interface

(

--organization_code

organization_id

, primary_item_id

, job_name

, start_quantity

, net_quantity

, first_unit_start_date --,SCHEDULED_START_DATE, SCHEDULED_COMPLETION_DATE 

, DATE_RELEASED

, class_code

, status_type

, COMPLETION_SUBINVENTORY

, group_id

, load_type

,WIP_SUPPLY_TYPE

, process_phase

, process_status

, created_by

, creation_date

, last_updated_by

, last_update_date

, description

)

values

(

--'MST' -- organization_id

121

,15834 -- primary_item_id

--,WIP_JOB_NUMBER_S.nextval -- job_name

,'SFF8006'

,2 -- start_quantity

,2 -- Net Quantity

,to_date('01-APR-2023','DD-MON-RRRR') --first_unit_start_date

,to_date('01-APR-2023','DD-MON-RRRR')--,to_date('01-APR-2023','DD-MON-RRRR') ,to_date('01-APR-2023','DD-MON-RRRR')  

,'SGL_AC_ST' --class_code

,3 --status_type 1.UnReleased 3. Released 4.Complete 6.On Hold 7. Cancelled

,'SP-CAB' --COMPLETION_SUBINVENTORY

,10 -- group_id to submit conc program 

,1 -- load_type

/*

1 Create Standard Discrete Job

2 Create Pending Repetitive Schedule

3 Update Standard or Non-Standard Discrete Job

4 Create Non-Standard Discrete Job

*/

,3

,2 -- process_phase 2 Validation 3 Explosion 4 Complete 5 Creation

,1 -- process_status 1 Pending 2 Running 3 Error 4 Complete 5 Warning

,1130 -- created_by

, SYSDATE -- creation_date

,1130 -- last_updated_by

, SYSDATE -- last_update_date

,'Test Description'

);


 /*

Navigation path: WIP - discrete - import jobs and schedules

Concurrent Program to import data :- WIP Mass Load

group_id = 1 (Same group id as in Interface Table)


Error table :- WIP_INTERFACE_ERRORS

https://oracleappss.blogspot.com/2008/07/wip-job-creation.html

*/

SELECT * FROM WIP_DISCRETE_JOBS_V 

WHERE CREATION_DATE LIKE SYSDATE

;


No comments:

Post a Comment