cancel
Showing results for 
Search instead for 
Did you mean: 

Error: The datatype object is not valid(Build Process Automation - BAPI Call)

sarathc
Explorer
0 Kudos

Dear Community and Experts,

I'm facing the below error in the Automation, the automation is to create Sales document in ECC and I have used BAPI Action Group in the process.

The BAPI call steps parameters are set with variables to create a Sales Contract. I get the error as "TARGET_QTY" must be number, on the contrary the JSON field for TARGET_QTY do not accept any other format than numbers.

I have checked several times the data type I used for TARGET_QTY from declaration of Data Type, Decision parameters, Automation Parameters all are updated as Number. I'm not sure where this error is from, totally lost! If any of you have come cross such errors and solved please convey how you resolved. For those who faced similar issue and continue please add your comments too.I have another automation where I have hard coded data in to the BAPI call step, there it works fine.

Thanks and Kind regards,

Sarath

Ivan-Mirisola
Product and Topic Expert
Product and Topic Expert
0 Kudos

Hi sharathkumarnair,

When you click on the "show JSON editor", do you see your number withing double-quotes or not?

Can you post the screen as well here?

Best regards,
Ivan

Accepted Solutions (0)

Answers (1)

Answers (1)

Venkat_Vyza
Active Participant

Hi @sharathkumarnair,

I think there are two ways to address this:

1. In the Automation, for the Input Parameters, you can choose Custom Data and create the required fields with the required data types.

OR

2. In the Overview screen, copy the automatically created BAPI Input Data Type and change the data type for that specific field and use that in the Automation Input parameters.

Please let me know the result.

Thank you,

Venkat Vyza

sarathc
Explorer
0 Kudos

Hi venkat_vyza,

Thanks for the response!

I'm using the first option as you mentioned.

The second did not work in the Decision's output parameter mapping. I think it was due to the deep structure of the BAPI parameters as few of them had data type as OBJECT.

Let me try to delete the particular structure and recreate it followed by the whole mapping. Meanwhile if you have any other suggestion please let me know.

Thank you,

Sarath

Venkat_Vyza
Active Participant
0 Kudos

Hi @sharathkumarnair,

Chaning the Data Type of the Number fields to "Any" is the solution as we discussed, in case of BAPI.

Thank you,

Venkat Vyza