Skip to main content
Solved

Functional Object creation via Migration Job

  • 25 July 2024
  • 2 replies
  • 65 views

Hi,

We have a requirement to create Functional Objects via Migration Job.  The job should also insert Belongs to Object and Contract.

In Cloud, while creating Migration Job (tried with Excel and Migrate Source Data) on EQUIPMENT_FUNCTIONAL, the columns SUP_MCH_CODE (Belongs to Object) and SUP_CONTRACT (Belongs to Site) not at all visible in Column mapping.

We tried using modify Method to update these columns, but still it is not updating and Migration Job ending with an error as below

API Methods used: EQUIPMENT_OBJECT_PARTY_API.Modify__ 

Also used this method, EQUIPMENT_FUNCTIONAL_API.MODIFY__ , but in both cases it ended with same error

Error:

ORA-06550: line 1, column 43:
PLS-00225: subprogram or cursor 'MODIFY__' reference is out of scope

Any thoughts or idea really helpful on this

Thanks,

Nishith

2 replies

Userlevel 5
Badge +10

Hi @NishithDas 

If you only want to update records then only set the “Modify” flag to Yes and the “New” flag to No.

 

But to be able to update existing records in that case you also have to do a “key manipulation” in the method list attribute screen for EQUIPMENT_FUNCTIONAL:

 

Here you have the column Flags for the yellow-marked column names. The problem is that you don’t know the value for EQUIPMENT_OBJECT_SEQ because this Oracle sequence will be generated.

To update existing records you have do define another primary key instead of the EQUIPMENT_OBJECT_SEQ.

So declare the fields CONTRACT and MCH_CODE as K(ey)-fields for that migration job and the EQUIPMENT_OBJECT_SEQ field will get a - (minus sign).

That’s it.

 

 

Related to your question regarding SUP_MCH_CODE and SUP_CONTRACT you have to map the field FUNCTIONAL_OBJECT_SEQ in the Source Mapping tab:

 

And here you can either sub-select statement in brackets in the source column or default value field:

I used the default value field for that purpose and kept the source column field empty.

The content for the default value field is the following:

 

The alias i belongs to the fields of my source table (source name).

 

Happy data migration.

 

/Jens

 

Userlevel 1
Badge +6

Hi Jens,

 

Thanks for your response.

 

We managed to resolve this issue. Initially when selected the View in Migration Job, the column  “FUNCTIONAL_OBJECT_SEQ” not initially available neither in Method List Attribute nor in Source Data Mapping.

We have added the above column in both Method List Attribute and Source Data Mapping and now it is working and able to link the Belongs to Site (SUP_MCH_CODE) and Belongs to Site (SUP_CONTRACT)

 

The column “FUNCTIONAL_OBJECT_SEQ” is being populated by the SQL suggested

Thanks,

Nishith

Reply