on 2015 Sep 17 10:31 AM
Hi Experts,
We are configuring the CLM application to store the Purchase Orders. So as part of solution, we will be receiving the information (Header +Item level) of the PO in form of a csv/xml. We are capturing all these information in an UDO with extension collections.
Can any one suggest, is there any way to load Header information along with Item level (Extension collection) at once.
Any pointers will be appreciated.
Regards,
Ravi
Request clarification before answering.
Hi Experts,
Please let me know if there is any possibility to migrate the header and line item information of PO to CLM with single file.
Br,
Ravi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hello Ravi,
You can load all info at once (header, collections, extensions, etc) only if you are using XML for transfer.
Bogdan
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.
Hi Bogdan,
Thanks for your suggestion.
As per your suggestion, i have tried to create an xml and perform the import, but it got failed.
Kindly suggest.
Please find the details below.
xml:
<?xml version="1.0" encoding="UTF-8"?>
<sapesourcing defaultlanguage="">
<objects>
<object classname="contracts.Contract">
<fields>
<DISPLAY_NAME>Testing MA Creation with XML</DISPLAY_NAME>
<DOCUMENT_DESCRIPTION></DOCUMENT_DESCRIPTION>
<EFFECTIVE_DATE></EFFECTIVE_DATE>
<RENEWAL_REMINDER>03/31/2015 11:36</RENEWAL_REMINDER>
<EXPIRATION_DATE>03/31/2015 11:36</EXPIRATION_DATE>
<COLLABORATOR_1>RAVI</COLLABORATOR_1>
<DOC_TYPE>ECC Integration</DOC_TYPE>
<UNIQUE_DOC_NAME></UNIQUE_DOC_NAME>
<STATUS>Preliminary</STATUS>
<CURRENCY>GBP</CURRENCY>
<VENDOR>VEN-005</VENDOR>
<COMPANY>ERICSSON</COMPANY>
<LOCATION_1>US</LOCATION_1>
<DOC_OWNER_USER>RAVI</DOC_OWNER_USER>
<DELIVERY_TERM_1>CIF</DELIVERY_TERM_1>
<PURCHASING_ORG>1070</PURCHASING_ORG>
<PURCHASING_GRP>MAD</PURCHASING_GRP>
<BUSINESS_SYSTEM>SAPECC8400</BUSINESS_SYSTEM>
<GENERATE_DOCUMENT_ID>TRUE</GENERATE_DOCUMENT_ID>
</fields>
<collections>
<MA_LINEITEMS>
<object classname="contracts.LineItem">
<fields>
<UNIQUE_DOC_NAME/>
<IS_PRODUCT>SAPECC8400</IS_PRODUCT>
<ITEM_TYPE>Material</ITEM_TYPE>
<DOCUMENT_DESCRIPTION>Line Item 1</DOCUMENT_DESCRIPTION>
<QUANTITY_NUMBER>1000</QUANTITY_NUMBER>
<QUANTITY_UNIT>EA</QUANTITY_UNIT>
<PRICE_UNIT>254</PRICE_UNIT>
<INCOTERM_ID>CIF</INCOTERM_ID>
<PRICE_CONDITION_ID_1>Z009</PRICE_CONDITION_ID_1>
<PRICE_CONDITION_ID_2>Z006</PRICE_CONDITION_ID_2>
</fields>
</object>
</MA_LINEITEMS>
</collections>
</object>
</objects>
</sapesourcing>
Error message:
Fri Sep 18 12:23:39 GMT+00:00 2015 | Importing XML File. | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ..Inserting XML data from file /usr/sap/F37/J21/esourcing-01/tmp/rtimport_7888219691532799704.xml | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ..Record 1. Warning: XML import could not process field: COLLABORATOR_1 | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ..Record 1. Warning: XML import could not process field: LOCATION_1 | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ..Record 1. Warning: XML import could not process field: DELIVERY_TERM_1 | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ..Record 1. Warning: XML import could not process field: BUSINESS_SYSTEM | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ..Record 1. Warning: XML import could not process field: GENERATE_DOCUMENT_ID | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ....Record 1. Warning: XML import could not process field: IS_PRODUCT | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ....Record 1. Warning: XML import could not process field: ITEM_TYPE | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ....Record 1. Warning: XML import could not process field: QUANTITY_NUMBER | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ....Record 1. Warning: XML import could not process field: QUANTITY_UNIT | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ....Record 1. Warning: XML import could not process field: INCOTERM_ID | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ....Record 1. Warning: XML import could not process field: PRICE_CONDITION_ID_1 | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ....Record 1. Warning: XML import could not process field: PRICE_CONDITION_ID_2 | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ..Record 1. Warning: ID: exception.common.importer.field.cannot_resolve_external_ref | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ..Record 1. Warning: ID: exception.common.importer.field.cannot_resolve_external_ref | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ..Record 1. Warning: Value for business system is missing. Enter a business system. | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ..Failed: object 1: com.sap.eso.contracts.importer.processors.ContractLineItemProcessor.<init>(com.sap.odp.common.db.metadata.CollectionMdIfc, java.lang.Integer) | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ..Complete. 0 ok. 1 failed. | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | ..Importing XML File. 0 ok. 1 failed. File rtimport_7888219691532799704.xml | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | Error during action failed to import data, 1 error(s). | |
Fri Sep 18 12:23:39 GMT+00:00 2015 | Problems were encountered processing file /usr/sap/F37/J21/esourcing-01/tmp/rtimport_7888219691532799704.xml. |
Hello Ravi,
The header structure is OK, but the issue is with the fields/collections.
The XML format requires 1:1 structure match with Contract BO.
Fields like "COLLABORATOR_1" are not valid (as per RefGuide); they are only used by the CSV importer to overcome the structure limitation in CSV.
To find out the correct structure you should use follow below steps:
1. Export one Contract in .oma format (via Setup-Export)
2. Rename file from .oma to .zip
3. Unzip and open "exported_objects.0.xml"
Analyse the exported XML, only looking at the <object classname="contracts.Contract"> itself.
Your final XML should be like this:
<sapesourcing>
<objects>
<object classname="contracts.Contract">
... aligned structure with exported oma contract
... just use your required fields, not all, and go 1 by 1 when encountering errors.
</object>
</objects>
</sapesourcing>
Bogdan
Hi Bogdan,
Thanks for your valuable input.
I have tried the way you have suggested, but still the system is not able to identify the custom fields.
Please find the updated xml message.
<?xml version="1.0" encoding="UTF-8"?>
<sapesourcing defaultlanguage="">
<objects>
<object classname="contracts.Contract">
<fields>
<UNIQUE_DOC_NAME>MA-2999-000001</UNIQUE_DOC_NAME>
<DISPLAY_NAME>Generate ID</DISPLAY_NAME>
<DOCUMENT_DESCRIPTION>Standared Master Agreement creation test via XML</DOCUMENT_DESCRIPTION>
<TRACK_CHANGES>true</TRACK_CHANGES>
<DOC_OWNER_USER>RAVI</DOC_OWNER_USER>
<DOC_TYPE>Standard Master Agreement</DOC_TYPE>
<COMPANY>Testing</COMPANY>
<CURRENCY>EUR</CURRENCY>
<EFFECTIVE_DATE>09/29/2015 11:36</EFFECTIVE_DATE>
<RENEWAL_REMINDER>03/31/2015 11:36</RENEWAL_REMINDER>
<EXPIRATION_DATE>2016-03-12</EXPIRATION_DATE>
<PERPETUAL_TERM>false</PERPETUAL_TERM>
<AUTO_RENEWAL>false</AUTO_RENEWAL>
<VENDOR>100000</VENDOR>
<STATUS>Initiated</STATUS>
</fields>
<collections>
<COLLABORATORS>
<object classname="doc.collaborator">
<fields>
<UNIQUE_DOC_NAME/>
<DISPLAY_NAME>Ravi</DISPLAY_NAME>
<PARENT/>
<COLLECTION_ORDER_CODE>1000</COLLECTION_ORDER_CODE>
<COLLABORATOR_TYPE>User</COLLABORATOR_TYPE>
<USER_NAME>ravi</USER_NAME>
<EMAIL_ADDRESS>ravi.gupta@gmail.com</EMAIL_ADDRESS>
<REPRESENTING>Purchasing</REPRESENTING>
<COLLABORATOR_ROLE>Owner</COLLABORATOR_ROLE>
<LOCK_ROLE>true</LOCK_ROLE>
</fields>
</object>
<object classname="doc.collaborator">
<fields>
<UNIQUE_DOC_NAME/>
<DISPLAY_NAME>BATCH USER</DISPLAY_NAME>
<PARENT/>
<COLLECTION_ORDER_CODE>2000</COLLECTION_ORDER_CODE>
<COLLABORATOR_TYPE>User</COLLABORATOR_TYPE>
<USER_NAME>BATCH_USER</USER_NAME>
<EMAIL_ADDRESS>sclm.technical@dummy.com</EMAIL_ADDRESS>
<REPRESENTING>Purchasing</REPRESENTING>
<COLLABORATOR_ROLE>Collaborator</COLLABORATOR_ROLE>
<LOCK_ROLE>true</LOCK_ROLE>
</fields>
</object>
</COLLABORATORS>
<DOCUMENT_EXTENSIONS>
<object classname="extension.dummy.context.contracts.contract" >
<fields>
<UNIQUE_DOC_NAME>Generate</UNIQUE_DOC_NAME>
<PARENT>MA-2999-000001</PARENT>
<DISPLAY_NAME>null</DISPLAY_NAME>
<Z_MA_CONFIDENTIAL>false</Z_MA_CONFIDENTIAL>
<Z_MA_REGION>INDIA</Z_MA_REGION>
<Z_MA_ERIC_PARTY>Dummy_Value</Z_MA_ERIC_PARTY>
<Z_MA_LAW>Algeria</Z_MA_LAW>
<Z_MA_TEMP_LEVEL>Global</Z_MA_TEMP_LEVEL>
<Z_MA_PARTY_NAME>TECHNOLOGIES INC.</Z_MA_PARTY_NAME>
</fields>
</object>
</DOCUMENT_EXTENSIONS>
</collections>
</object>
</objects>
</sapesourcing>
Br,
Ravi
You must be a registered user to add a comment. If you've already registered, sign in. Otherwise, register and sign in.