库存货位分配到错误的子库存下,导致无法再正常分配到其他的子库存。只能考虑调用标准API删除。
DECLARE l_msg_data VARCHAR2(100); l_msg_count NUMBER; l_return_status VARCHAR2(1); l_locator_id NUMBER; l_locator_exists VARCHAR2(1); BEGIN /* APPS_INITIALIZE required because indirectly use profile options */ fnd_global.apps_initialize(1150, 50963, 401); fnd_profile.put('MFG_ORGANIZATION_ID', 90); fnd_msg_pub.initialize; inv_loc_wms_pub.delete_locator(x_return_status => l_return_status, x_msg_count => l_msg_count, x_msg_data => l_msg_data, p_inventory_location_id => NULL, p_organization_id => 90, p_organization_code => 'T2S', p_concatenated_segments => 'WPH_001.1.T2S0003.0000.一等', p_validation_req_flag => 'Y'); COMMIT; dbms_output.put_line('Return Status ' || l_return_status); IF l_return_status IN ('E', 'U') THEN dbms_output.put_line('# of Errors ' || l_msg_count); IF l_msg_count = 1 THEN dbms_output.put_line('Error ' || l_msg_data); ELSE FOR i IN 1 .. l_msg_count LOOP dbms_output.put_line('Error ' || fnd_msg_pub.get(i, 'F')); END LOOP; END IF; ELSE dbms_output.put_line('Locator Id is ' || l_locator_id); END IF; END;