Understanding Item Import and Debugging Problems with Item Import (Doc ID 268968.1)
In this Document
Purpose
Details
Scenario 1: Testing the basic item import with minimum columns populated
Scenario 2: To import items and use item templates
Scenario 3: To import items and material cost associated to it.
Scenario 4: To import item and revisions associated to it
Scenario 5: Import more than two revisions along with item creation
Scenario 6: Import item categories along with items.
Scenario 7: Import item catalogs along with items.
Scenario 8: How to update existing items.
Scenario 9: How to populate character and number columns and make it null
Frequently Asked Questions (FAQ):
a. How do I know what error has occurred?
b. What things should I check if I getting errors?
c. I run item import but records are not getting processed. The process_flag is still 1.
d. What do I do to check more in to errors and see where the import is failing?
e. 11.5.9 Item import issues and patches to be applied.
f. List of documents required while logging a tar on item import.
g. Some examples of errors and what it might mean
h. Is there an API for Item creation and updation?
References
APPLIES TO:
PURPOSE
When you import items through the Item Interface, you create new items in your Item Master organization or assign existing items to
additional organizations. You can specify values for all the item attributes, or you can specify just a few attributes and let the remainder
default or remain Null. You can also specify an item template for each item and inherit attribute values from the template. The Item
Interface also lets you import revision details, including past and future revisions and effectivity dates. Validation of imported items is
done using the same rules as the item definition forms, so you are insured of valid items.
The Item Interface reads data from two tables for importing items and item details. You use the MTL_SYSTEMS_ITEM_INTERFACE table
for new item numbers and all item attributes. This is the main item interface table, and can be the only table you choose to use. If you
are importing revision details for
new items, you can use the MTL_ITEM_REVISIONS_INTERFACE table.
A third table, MTL_INTERFACE_ERRORS, is used for error tracking of all items that the Item Interface fails. You can import item
categories using interface table called as MTL_ITEM_CATEGORIES_INTERFACE.
Before you use the Item Interface, you must write and run a custom program that extracts item information from your source system
and inserts it into the MTL_SYSTEM_ITEM_INTERFACE table, and (if revision detail is included) the MTL_ITEMS_REVISIONS_INTERFACE
table. After you load the items into these interface tables, you run the Item Interface to import the data. The Item Interface assigns
1 of 12 11/11/2016 1:34 PM
Document 268968.1 https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.c...
defaults, validates data you include, and then imports the new items. You may also specify an item template for each item being
imported.
You must import items into the Item Master organization before you import items into additional organizations. You can accomplish this
by specifying only your Item Master organization on first run of the Item Interface. Once this has completed, you can run the Item
Interface again, this time specifying an
additional or all organizations. You can also use the Item Interface to import a single item material cost and material overhead, and
revision details.
Below we will walk through few scenarios of item import and provide answers to frequently asked questions.
DETAILS
Scenario 1: Testing the basic item import with minimum columns populated
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
First always try to populate the master organization with a sample record and test.
ORG ORGANIZATION_ID
--- -------------------------------
V1 204
M1 207
M2 209
M3 606
M4 1641
M5 1642
M6 1643
M7 1644
In the above example for organizations M1 to M7, V1 organization is the master organization.
Populating V1 organization with one new item using just the basic columns.
2 of 12 11/11/2016 1:34 PM
Document 268968.1 https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.c...
In the above insert Process_Flag = 1. Only when process_flag = 1 will the item import program process the record. Set_Process_Id = 1.
You can set which ever number you want for this column. This is basically used like a batch number. You can tell item import which set
of records to process by entering a set_process_id.
Transaction_Type is 'CREATE' when you are inserting new records and 'UDATE' when you are updating existing records.
We are using i.e. organization_id 204 which is for master organization V1. Note: If you have more than one segment defined for items
please populate all those segments. To check which segments to be populated please got to: Setup > Flexfields > Key > Segments .
Now query up 'System Items' by putting
it in flexfield title. Select segments button, and now you should be able to see the different segments being defined.
Now run the item import program ie. Item > Import > Import Items. In Process Set enter 1 as we had used 1 in the set_process_id
column. Now enter 1 in create or update items field and hit OK button. You can check view requests to check whether your request has
completedsuccessfully. Now go to Master Items screen and query on 'TESTITEMIMPORT' the item that we had populated and you
should be able to see the item.
Similarly you can import the same item for the child organization. Eg. we want item 'TESTITEMIMPORT' in organization M1 say Seattle
manufacturing then all you have to do is replace the organization_id by M1 organization_id. Now the insert statement will look like this.
insert into mtl_system_items_interface
(process_flag, set_process_id, transaction_type,organization_id,segment1,description)
values (1,1,'CREATE',207,'TESTITEMIMPORT', 'Testing Item Import');
commit;
This works when attributes are controlled at org level. For attributes controlled at Master level, you should insert in MSII the same value
of the attribute as it is already setup in MSIB.
Run the item import with the same parameters and then check if the concurrent request has completed successfully. Now do Change
Organization and go to Organization Item screen and query up TESTITEMIMPORT and you should be able to see the item in M1
organization.
To see all the attributes related to template run the following sql:
select template_id,attribute_name,enabled_flag,report_user_value
from MTL_ITEM_TEMPL_ATTRIBUTES where template_id = &template_id;
Please subsitute the template id from the 1st query in the second query to see the attribute values.
In our example, we use Purchasing Template.
select template_id,template_name,description
from MTL_ITEM_TEMPLATES
where template_id = 259;
We are going to insert a new item in the master organization and use the purchasing template.
Now run the item import program ie. Item > Import > Import Items. In Process Set enter 1 as we had used 1 in the set_process_id
column. Now enter 1 in create or update items field and hit OK button. You can check view requests to check whether your request has
completedsuccessfully.
Now go to master items screen and query on 'TESTTEMPLATE' the item that we had populated and you should be able to see the item.
Now you will see that the purchasing attributes are set because we used the purchasing template.
Note: Instead of using template_id you can use template_name and you should see the same effect.
3 of 12 11/11/2016 1:34 PM
Document 268968.1 https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.c...
First check which cost elements are defined for the organizaion:
select cost_type_id,cost_type,description from CST_COST_TYPES;
To find the sub element name defined for your organization for a particular cost type please check bom resources table. In our example
we are checking for material sub element in organization M1 with organization_id = 207 for cost_code type 1.
select resource_code,description,cost_element_id,cost_code_type
from bom_resources where organization_id = 207
and cost_code_type= 1;
In our scenario we want to create a new item in organization M1 along with its material cost (say $11) assuming the same item is
already created in master organization V1.
In the above sql you might have observed we are populating MATERIAL_COST and MATERIAL_SUB_ELEM. Similary we can use
MATERIAL_SUB_ELEM_ID, MATERIAL_OH_RATE, MATERIAL_OH_SUB_ELEM and MATERIAL_OH_SUB_ELEM_ID colums. To check the
subelements you can go to Cost management responsibility for your organization and under Setup > Sub-Elements you will see the
respectivesubelements being defined.
Now run the item import program ie. Item > Import > Import Items. In Process Set enter 1 as we had used 1 in the set_process_id
column. Now enter 1 in create or update items field and hit OK button. You can check view requests to check whether your request has
completed successfully. Now go to organization items and query on 'TESTCOSTMATERIAL' the item that we had populated and you
should be able to see the item.
Go to Tools > Item Costs and then hit Open button from Item Cost Summary screen and you should see the details. In out example we
see a material cost of $11 for the item in cost type 'Frozen'(Standard Costing).
4 of 12 11/11/2016 1:34 PM
Document 268968.1 https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.c...
Mode to run this request : A LOV is provided with possible two values , 'Insert new cost' or 'Remove and replace cost'. The 'Insert new
cost' mode , is useful if you are importing large # of items and are not sure if that Item/Organization/Cost Type combination already
exists in the production tables, if it does then the row in the interface table would be flaged as errored and not imported.This would
prevent any accidental overwrite of already existing data.
With 'Remove and replace cost' mode all the previous cost information for this item, cost_type and organization combination will be
deleted from the production tables and the new information will overwrite (replace) the already existing one.
Group Id Option: A LOV is provided from which the user can either select 'ALL' or 'Specific Group Id' . If the user wishes to submit
multiple Cost Import process requests he can do so by submitting one request per group id. For doing so the data in the interface tables
should be stamped with distinct group id value by using the NEXTVAL from the sequence generator CST_LISTS_S .The use of this
sequence geneartor is a MUST for generating multiple groups or may lead to data corruption as these interface tables are used by other
processes too.
If the user selects "ALL" from the list then a group ID generated by a sequence will replace the group ID in the interface tables (if any)
and all the unprocessed rows from the four interface table (viz.cst_item_cst_dtls_interface, cst_resource_costs_interface,
cst_res_overheads_interface, cst_dept_overheads_interface ) will be processed in one run.
Cost type to import to: The user is provided with a LOV from which he needs to select the cost type in which he wishes to import the
cost information. Even if the user has populated a cost type or cost type ID in the interface tables, it would be overwritten with the one
that is selected here. The cost types that the user can pick from is restricted to the multi-org, updateable cost types.
Delete succesfull rows: This parameter decides whether the successfully processed rows should be deleted from the interface tables at
the end of the run. If the user selects 'Yes' then all the successful rows be deleted, basically rows that do not have their error flag set to
"E".
Importing directly into Frozen/Average cost type (i.e non updateable cost types) and merging of new cost with existing costs is not
supported at this time and would still have to be processed by cost update routines. Also when importing the costs from the interface
table ,material overhead defaults (if any)
specified for an Organization/Category would not be respected.
a. Inventory_item_id
b. organization_ID or organization_code.
c. resource_ID or resource_code for cost elements other than 1(material).
If we are importing cost into material cost element and default material subelement has been specified on 'Define
Organization parameters' form then that would be respected unless the user overides it with a value in this column.
d. usage_rate_or_amount
e. cost_element_ID or cost_element
f. Process Flag (must be set to 1)
We default values for based_on_rollup, shrinkage_rate, inventory_asset_flag, lot_size from the row from CST_ITEM_COSTS for this item
and the default cost type(default cost type of the cost type specified to import the costs into). If there is no such row already defined in
CST_ITEM_COSTS, then, the values for these 4 columns also need to be specified and they have to be the same for all rows of this item,
cost type and organization combination.
CST_RESOURCE_COSTS_INTERFACE
a. Resource_ID or resource_code
b. organization_ID or organization_code
c. resource_rate
d. Process_flag (must be set to 1)
CST_RES_OVERHEADS_INTERFACE
a. Resource_ID or resource_code
b. Overhead_ID or overhead
c. Organization_ID or organization_code
d. Process_flag(must be set to 1)
CST_DEPT_OVERHEADS_INTERFACE
a. Department_ID or department
b. Overhead_ID or overhead
5 of 12 11/11/2016 1:34 PM
Document 268968.1 https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.c...
c. Organization_ID
d. Rate_or_amount
e. Process_flag(must be set to 1)
When ever you import a new item based on the Starting revision specified under 'Revison/Lot/Serial' tab in organization parameters
screen the default revison gets assigned to the item. For eg. the default revision in V1 organization is 'A' when we do item import this
revision gets associated to the item.
Now lets import a new item with revision 'B' which is not the default revision.
insert into mtl_system_items_interface
(process_flag, set_process_id, transaction_type,organization_id,segment1, description,REVISION)
values
(1,1,'CREATE',204,'TESTREVB1', 'Testing Item Revision','B');
Now run the item import program ie. Item > Import > Import Items. In Process Set enter 1 as we had used 1 in the set_process_id
column. Now enter 1 in create or update items field and hit OK button. You can check view requests to check whether your request has
completed successfully.
Now go to organization items and query on 'TESTREVB1' the item that we had populated and you should be able to see the item. Go to
Tools > Revisions and then you should be able to see two records one with revision 'A' which is the default revision and another with
revision 'B' that we had populated.
In case you want to import a new revision say revision 'C'. You directly populate the MTL_ITEM_REVISIONS_INTERFACE table and then
run item import.
insert into MTL_ITEM_REVISIONS_INTERFACE
(item_number,revision, revision_label,implementation_date, effectivity_date, process_flag, organization_id ,set_process_id,
transaction_type)
values
('TESTREVB1','C','C',sysdate,sysdate,1,204,1,'CREATE');
Commit;
Now run the item import. In Process Set enter 1 as we had used 1 in the set_process_id column. Now enter 1 in create or update items
field and hit OK button. You can check view requests to check whether your request has completed successfully. When you query up the
item 'TESTREVB1' You will see the new revision 'C'.
Scenario 5: Import more than two revisions along with item creation
We will be populating MTL_ITEM_REVISIONS_INTERFACE. The key point here is the IMPLEMENTATION_DATE should increment
cronologically.
6 of 12 11/11/2016 1:34 PM
Document 268968.1 https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.c...
Now run the item import program ie. Item > Import > Import Items. In Process Set enter 1 as we had used 1 in the set_process_id
column. Now enter 1 in create or update items field and hit OK button. You can check view requests to check whether your request has
completed successfully. Now go to organization items and query on 'TESTREVB2' the item that we had populated and you should be able
to see the item. Go to Tools > Revisions and then you should be able to see three records one with revision 'A', another with revision 'B'
and the thrid one is 'C' that we had populated.
Note: We have been inctementing the minutes section by sysdate+.0003472 and sysdate+.0023472 so that the implementation date is
in cronological order.
7 of 12 11/11/2016 1:34 PM
Document 268968.1 https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.c...
Now run the item import program ie. Item > Import > Import Items. In Process Set enter 1 as we had used 1 in the set_process_id
column. Now enter 1 in create or update items field and hit OK button. You can check view requests to check whether your request has
completed successfully. Now go to organization items and query on 'TESTCATG1' the item that we had populated and you should be
able to see the item. Go to Tools > Categoriess and then you should be able to see category Dairy associated to the item.
NOTE: Populating set_process_id is mandatory for categories import. Please put the same set process id when you run the import
program.
Run item import.In Process Set enter 1 as we had used 1 in the set_process_id column. Now enter 2 in create or update items field as
we are updating the exsisting item and changing its category. Hit OK button. You can check view requests to check whether your
request has completed successfully.
When you query up item 'TESTCATG1' and select the categories from tools you will find that the category 'BAKERY' is now asscoiated
with the item.
select ITEM_CATALOG_GROUP_ID,ELEMENT_NAME,ELEMENT_SEQUENCE,DESCRIPTION
from mtl_descriptive_elements
where ITEM_CATALOG_GROUP_ID = 161;
Now run the item import program ie. Item > Import > Import Items. In Process Set enter 1 as we had used 1 in the set_process_id
column. Now enter 1 in create or update items field and hit OK button. You can check view requests to check whether your request has
completed successfully. Now go to organization items and query on 'TESTCATA1' the item that we had populated and you should be able
to see the item. Go to Tools > Catalogs and then you should be able to see 'ADSL Modem' along with descriptive elements '2wire' and
'linksys'. In 11.5.9 you have to manually enter the values for descriptive elements. In 11.5.10 API to import descriptive element values
will be present.
8 of 12 11/11/2016 1:34 PM
Document 268968.1 https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.c...
Let's say we have an item 'ODC' which has no buyer code in Seattle organization (M1 organization code). Need to update and asscoiate
'West, Rod' as buyer to the item 'ODC'. First we check under Setup > Items > Attribute Contol to check if it controlled at the
organization level or master level. In our case the attribute is controlled at the Org Level. Now we check if Rod exists in the list of valid
buyers.
select agent_id,agent_name,start_date_active,end_date_active
from PO_AGENTS_V where agent_name like '%Rod%';
Now run the item import program ie. Item > Import > Import Items. In Process Set enter 1 as we had used 1 in the set_process_id
column. Now enter 2 in create or update items field and hit OK button. You can check view requests to check whether your request has
completed successfully. Now go to organization items and query on 'ODC' item in M1 organization. Under purchasing tab you will see
that the buyer 'West, Rod' populated.
Note: INCOIN does not support updating item numbers. Enhancement request 6507704 already logged for this.
Scenario 9: How to populate character and number columns and make it null
Just from our above example we have buyer 'West, Rod' populated for item 'ODC'. Now for some reason we want to make null for buyer
for item ODC. Buyer id column is a number column. To make it null we have to populate -999999.
Now run the item import program ie. Item > Import > Import Items. In Process Set enter 1 as we had used 1 in the set_process_id
column. Now enter 2 in create or update items field and hit OK button. You can check view requests to check whether your request has
completed successfully. Now go to organization items and query on 'ODC' item in M1 organization. Under purchasing tab you will see
that the buyer field is updated to null.
Suppose planner 'S.Peters' is asscoiated to item ODC. You want to make it null. PLANNER_CODE in mtl_system_items_interface is a
charracter type. To make it null we have to use '!'.
insert into mtl_system_items_interface
(process_flag, set_process_id, transaction_type, organization_id, inventory_item_id, PLANNER_CODE)
values
(1,1,'UPDATE',207,9372,'!');
commit;
Now run the item import program ie. Item > Import > Import Items. In Process Set enter 1 as we had used 1 in the set_process_id
column. Now enter 2 in create or update items field and hit OK button. You can check view requests to check whether your request has
completed successfully. Now go to organization items and query on 'ODC' item in M1 organization. Under general planning tab you will
see that the planner is updated to null.
9 of 12 11/11/2016 1:34 PM
Document 268968.1 https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.c...
Note: To make number columns null use -999999 and to make character columns null use '!' exclamation.
Ans . The process_flag in mtl_system_items_interface will be 3. Now the error message will be in mtl_interface_errors table. The record
in mtl_system_items_interface will have a transaction_id. There will be corresponding record with error code and explanation in
mtl_interface_errors.
select transaction_id from mtl_system_items_interface where process_flag = 3;
Now substitue the &transaction_id value in the following sql by the value that you get in the ablove sql. You should be able to see the
error.
select message_name,column_name,error_message from mtl_interface_errors
where transaction_id = &transaction_id;
Ans. First check if you are populating the correct values in all the fields. Then check if there are any mandatory descriptive flexfield
columns. You can go to application setup > flexfields > descriptive > segments and on query type ?Items? in title field and then check
each segment whether it is mandatory
and whether it is doing any validation against some pre-existing values in some value set. If so check if the corresponding attributes are
populated properly. Many times user forgets to populate mandatory values and item import fails.
Also check for invalid objects
Select object_name,object_type from all_objects where status = 'INVALID';
If any invalid objects please recompile those and retest item import.
c. I run item import but records are not getting processed. The process_flag is still 1.
Ans. Check under sysadmin> concurrent managers whether inventory namager is running. Then check if there is suffcient memory and
extent spaces. Use Note 1019721.6 and Note 1020085.6 to determine if there is a memory or extents issue. Check if there is sufficient
roll back segments, system global area and tablespace. Use the following truncate, this frees up space.
Now try importing one record and see if you are able to import it successfully. If you see ORA-1654 happens while inserting records into
mtl_pending_item_status table in the log file (01654, 00000, "unable to extend index %s.%s by %s in tablespace %s") please use
ALTER TABLESPACE ADD DATAFILE statement to add one or more files to the tablespace indicated.
d. What do I do to check more in to errors and see where the import is failing?
2. After setting the above system profile values go to Sysadmin > Concurrent > Program > Define. Query on short name 'INCOIN'. Now
check enable trace and save. Now run the item import the log file of item import will give more details.
Note: A log file may not be generated in the directory, what development wants is the concurrent request log file after the above
settings are done.
To identify the correct trace file please run the following query:
select request_id,oracle_process_id
from fnd_concurrent_requests
where request_id = &request_id;
10 of 12 11/11/2016 1:34 PM
Document 268968.1 https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.c...
Please substitute &request_id by the correct request id from the concurrent program. The trace file in the trace directory would have the
number that you get for oracle_process_id from the above query as a part of the file name.
eg: if oracle_process_id = 22771
The file could be ora22771.trc
^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
1. Cannot create items - Patch 3215473
2. INV_IOI_REV_BAD_ORDER error message for revisions - Patch 3226359
3. Item import fails with no error message - Patch 3226359
4. Item import completes but process_flag = 4 and set_process_id = -999
- Patch 3226359
5. If duplicate records for one master IOI does not import child recs for
other master records. The error message that you will get is "This Child
Item has no Master Item record in MTL_SYSTEM_ITEMS" - Patch 3474468
1. Dump of records in all 4 interface tables (in excel spread sheet including
column headers) MTL_SYSTEM_ITEMS_INTERFACE,MTL_INTERFACE_ERRORS,
MTL_ITEM_REVISIONS_INTERFACE and MTL_ITEM_CATEGORIES_INTERFACE before running import and after running import.
2. Output of BOMCHECK.sql See Note 244145.1
3. Raw Trace, Tkprof of trace and log files after doing settings recommended in section d( What do I do to check more in to errors and
see where the import is failing?) above.
4. Version of INCOIN from the server.
a. Sometimes users are unable to import items to child organization. They might get error
DEFAULT_INCLUDE_IN_ROLLUP_FLAG,INVENTORY_ITEM_STATUS_CODE,
INVENTORY_PLANNING_CODE,PLANNER_CODE,PLANNING_MAKE_BUY_CODE,
FIXED_LOT_MULTIPLIER,ROUNDING_CONTROL_TYPE,CARRYING_COST
Check the corresponding attribute values. If planner code is set at Master level please make it organization level.
(Ref. Oracle Inventory User Guide pg 5-52 - General Planning Attribute Group)
"Planner Code This attribute is controlled at the Organization level only."
Refer to Note 760498.1 - Item API Or Concurrent Manager, Which One Is Best For Item Creation?
REFERENCES
NOTE:760498.1 - Item API Or Concurrent Manager, Which One Is Best For Item Creation?
NOTE:1347604.1 - INCOIN: Why Should the Interface Tables Be Truncated
11 of 12 11/11/2016 1:34 PM
Document 268968.1 https://support.oracle.com/epmos/faces/DocumentDisplay?_adf.c...
12 of 12 11/11/2016 1:34 PM