Solved

Too many declaration error in migration job

  • 21 July 2022
  • 4 replies
  • 104 views

Userlevel 1
Badge +1

i want to create a migration job  using a method  ,that method name define two times in a package.

ex, Create_Purchase_Order  method define in Purchase_Order_Api , one has 6 parameter and other one has more than 6 parameters .

I'm using the method with 6 parameters, but when i try to execute the migration job getting following errors, 

any idea how to use these type of method in migration jobs?

attached images.

icon

Best answer by Tomas Ruderfelt 25 July 2022, 09:54

View original

4 replies

Userlevel 7
Badge +19

The problem is that the 6 first parameters in both methods have exactly same data type + that the rest of the parameters does not need to be used.

Oracle can’t determine which one you want to call unless you specify the names of the parameters with “order_no_ => ‘123’” etc. and that does migration jobs not do.

Userlevel 1
Badge +1

Thank you so much for your reply Tomas, Sorry for disturbing again, you mean can't we use like these methods in Migration jobs?

or is there any special way to define parameter like above?

 

Userlevel 7
Badge +19

Yes, the six parameter method you cant use, but you can use the other one if you specify 7 parameters or more.

You could do a work around to call the 6 parameter method. The first thing that comes to my mind is that you create a custom LU with 6 attributes. Then you load data into that LU from the migration job. Before that you create a custom event on the custom LU to run the 6 parameter method on insert into the custom LU. Then it will run when you execute the migration job.

Userlevel 1
Badge +1

Hi Tomas, 

i tried this as your suggestions and it works fine, Thank you so much for your suggestions and sorry for late reply.

BR

/Ilsha

Reply