Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Problem When Calling Webservice

debdatta_panda
Participant
0 Likes
1,260

Hi Experts,

                  I have developed one RFC for update some database field through web service..My RFC function module is working fine.But when I am accessing this RFC through web service the database table is not updated.Please give me the solution..

9 REPLIES 9
Read only

Former Member
0 Likes
1,036

just guessing... do you have commit work (and wait) in your code?

Read only

Former Member
0 Likes
1,036

Hi,

Try using BAPI_TRANSACTION_COMMIT inside RFC and check whether it updates or not.

Thanks and Regards,

Ranadev

Read only

0 Likes
1,036

Hi Ranadev,

                      After using BAPI_TRANSACTION_COMMIT,I am facing another problem..The problem is that when I am accessing the RFC from se37 and then it is updating my table data.But when I am going to updata database data through web service then it is not updated..One thing is that for testing purpose I have passed two parameter in my RFC one is A another is B..And also there is a export parameter C..

Then I have written the code at the last line of RFC..The code is C = A + B..

Then it is returning value..But when I am entering this code after the code where my database is being updated then the returning value of C is 0..

Please give me a solution..

Read only

0 Likes
1,036

Hi,

Please test the webservice using SOAP UI and putting an external break point or an SRDEBUG.

It will solve the problem.

Regards,

VS

Read only

0 Likes
1,036

Hi,

    Can I debug my RFC function module on that way??How it is possible???Please tell me..

Read only

0 Likes
1,036

Hi,

Put an external breakpoint in your RFC using the ID "TEST".

Test the webservice by using the same ID "TEST" to hit the ECC. Your breakpoint will work.

Regards,

VS

Read only

0 Likes
1,036

Hi Deb,

Check the sy-subrc value after database commit, populate the return parameter of type BAPIRET2 to check any exception is happening or not. Call this RFC from your web service and check the Return parameter of type BAPIRET2 used as exporting parameter in RFC. In your RFC the return parameter should be populated from the return parameter passed from BAPI_TRANSACTION_COMMMIT.

Pls check one more thing  though its a very basic of RFC that the import and export parameters are PASS BY VALUE not PASS BY REFERENCE.

Thanks,

Ranadev

Read only

Former Member
0 Likes
1,036


Hi DEBDATTA,

You want to Debug the webservice or you want to test the function module?

In case if u want to test the webservice in debugging, you can do this from R/3 system directly,Put a break point in ur function module initially.

Go to SE80-> Open the package where the web service is saved->double click on the webservice->

Click on test in the tool bar-> then u will get a pop up , click on execute-> Then a screen will come where u can give the input data and then again execute.

You will now go to debug point.

Regards

AR

Read only

Former Member
0 Likes
1,036

Hi,

Along with all of the other useful replies about testing your web service and remote debugging, you may also want to explore the use of FBGENDAT in your RFC - this can be invaluable to help with understanding what data is being passed in from outside your system.

As someone has already mentioned, I'd also recommend using SOAP UI to test your service.

Cheers,

G.