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

Writing a java program to access SAP tables using SAP JCO

Former Member
0 Likes
1,560

Hi all,

I have a requirement where I need to access the VBAK table and get some values out of it based on a query on some of it fields. I would like to know how this can be done via a Java program by utilising the SAP JCo library. Has anyone done this before? A sample program would be very helpful.

Thanks in advance!

1 ACCEPTED SOLUTION
Read only

former_member222860
Active Contributor
0 Likes
942

Hi,

Yes, u should RFC function module to invoke the table entries.

Use the following RFM, this is apt for ur requirement

RFC_GET_TABLE_ENTRIES

thanks

Mahesh

6 REPLIES 6
Read only

Former Member
0 Likes
942
Read only

0 Likes
942

Hi Nikita,

I see that the PDF has info abt invoking BAPIs via java. Do you mean to say that I need to invoke a RFC to access any table? Or is there some other method?

Read only

Former Member
0 Likes
942

hi

have a look at the code in the thread below

hope it helps

regards

Aakash Banga

Read only

Former Member
Read only

former_member222860
Active Contributor
0 Likes
943

Hi,

Yes, u should RFC function module to invoke the table entries.

Use the following RFM, this is apt for ur requirement

RFC_GET_TABLE_ENTRIES

thanks

Mahesh

Read only

0 Likes
942

HI all,

Thanks much for the replies. I am now using RFC_READ_TABLE for my requirement. Appreciate the help! The other option could be to use RFC_GET_TABLE_ENTRIES as Mahesh rightly pointed out.