My Oracle Support Banner

Creating a New Lot Via Pending Product Lot Api, With Custom Lot Hook Enabled , Does Not Pass All Available Parameter Values To Inventory Lot Api. (Doc ID 2394705.1)

Last updated on APRIL 15, 2021

Applies to:

Oracle Process Manufacturing Process Execution - Version 12.2.6 and later
Information in this document applies to any platform.


On : 12.2.6 version, API Issues


Creating a new lot via pending product lot api, does not pass all available parameter values to inventory lot api.
This is a problem when using user_pkg_lot (lots custom hook) to generate custom lot numbers and the code needs the parameter values to generate the customer specific lot. 

API inv_lot_api_put.auto_gen_lot is called from gme_pending_product_lots_pvt, but NULL is being passed for most of the available parameters. The following is the actual call made in the GME code.

Note: "**" are the parameter values that were missing.

  x_mmli_tbl (i).lot_number := inv_lot_api_pub.auto_gen_lot
    (p_org_id => p_organization_id
    ,p_inventory_item_id => p_inventory_item_id
    ,p_lot_generation => NULL
    ,p_lot_uniqueness => NULL
    ,p_lot_prefix => NULL
    ,p_zero_pad => NULL
    ,p_lot_length => NULL
    ,p_transaction_date => NULL
    ,p_revision => NULL
    ,p_subinventory_code => NULL                                        **
    ,p_locator_id => NULL                                                      **
    ,p_transaction_type_id => NULL                                       **
    ,p_transaction_action_id => NULL                                     **
    ,p_transaction_source_type_id => NULL                           **
    ,p_lot_number => NULL                                           
    ,p_api_version => 1.0                                           
    ,p_init_msg_list => fnd_api.g_false                             
    ,p_commit => fnd_api.g_false                                    
    ,p_validation_level => NULL                                     
    ,p_parent_lot_number => NULL                                    
    ,p_transaction_source_id => l_batch_id                                **
    ,p_transaction_source_line_id => p_material_detail_id           **
    ,x_return_status => x_return_status
    ,x_msg_count => l_msg_count
    ,x_msg_data => l_msg_data);

It is expected that all parameter values accepted by the Inventory auto_gen_lot api be passed in when possible.

The issue can be reproduced at will with the following steps:
1. Run gme_api_pub.create_pending_product_lot for a specific product in a specific batch.
2. Production Supervisor->Batch details.
3. Load batch -> products tab-> drill into pending product lots.
4. Lot generated is not generated properly as many values are not available to custom code in user_pkg_lot.generate_lot_number.

The issue has the following business impact:
Due to this issue, users cannot fully implement custom lot generation code.


To view full details, sign in with your My Oracle Support account.

Don't have a My Oracle Support account? Click to get started!

In this Document

My Oracle Support provides customers with access to over a million knowledge articles and a vibrant support community of peers and Oracle experts.