Showing results for 
Search instead for 
Did you mean: 

BAPI call from Java

Former Member
0 Kudos

Hi all,

I'm trying to execute a BAPI from Java called "BAPI_SERVICENOTIFICAT_CREATE".

It creates a Service Notification for a functional location.

This BAPI WORKS WELL if I execute it from SAP (trans. SE37), but it gives me an error message I think it's incorrect.

" E020 Functional location PROM-DIA does not exist"

The import parameters (from Java and from SAP) are:

Structure "NOTIF_HEADER":

Field NOTIF_TYPE: "S1"

Field FUNCLOC: "PROM-DIA" (Of course, IT EXISTS...)

Field CONTACT: "0000000000"

Field DESCRIPT: "Do it from Java"

Any ideas?



Accepted Solutions (0)

Answers (1)

Answers (1)

Former Member
0 Kudos


Seems like you are not setting the proper values in the BAPI, you cpould do onething, take out each and every data you set it in the BAPI and take these valid values and compare it with the ones you are passing to your JCO.Function.

JCO.Function has a method writeToHTML or writeHTML(file name), before executing the function put this statement and after executing also put this statement




See the returnerd values in both the cases and compare it with your valid values.

Seems like BAPI is getting executed properly there is a problem in setting the values.