cancel
Showing results for 
Search instead for 
Did you mean: 

how to read BAPI Metadata

p_k3
Participant
0 Kudos

Dear All,

can you let me know how to read a BAPI's metadata.

I want to develop a sample webdynpro application that will fetch the metadata of a BAPI. Can any one let me know if there is any BAPI which will help me read the metadata.

thanks in advance

PK

Accepted Solutions (0)

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi,

Please refer to the following links for model creation and other metadata retrieval from BAPI.

http://help.sap.com/saphelp_nw04/helpdata/en/d5/1558bfa6aa80499113983e738b1b21/frameset.htm

[Other Relevant Link| [original link is broken];jsessionid=(J2EE3414900)ID1990530050DB02904298548410356825End#19]

Regards,

Tushar Sinha

Edited by: Tushar Sinha on Nov 18, 2009 4:09 AM

p_k3
Participant
0 Kudos

Hi Satish and Tushar,

thanks for your replies.

But what I am looking for is different from what you have suggested me to do.

I want to develop an application which will "DISPLAY" a BAPI's metadata ..... It should display the metadata of any BAPI whose name will be entered in the InpurFiled by the user. The application should take the BAPI's name from the InputField and fetch its metadata and DISPLAY it in the application. It should fetch all the info like Import, Export and table parameters.

I googled it and found a reply in some forum. There seems to be one BAPI named BAPI_INTERFACE_GETDOCU which would read the documentation of a specific business object residing in R3 but it wont return metadata of any BAPI.

Can any one help on this

former_member222860
Active Contributor
0 Kudos

I hope this Function Module suits the requirement

SWO_QUERY_FUNCTION_PARAMETERS

p_k3
Participant
0 Kudos

Hi Mahesh,

thanks for your reply (rewarded points to you ).

The function module you mentioned is retrieving the details I wan but looks like i cant use it in my WebDynpro application because it doesnt seem to have any BAPI . Is there any BAPI or some other function module which has a BAPI whose model I can import and use in my application?

Former Member
0 Kudos

Hi P K,

I am afraid to say there are no standard function module that can retrieve any other function modules' metadata (import and export parameters and table structures) that is remode enabled to be called by Web Dynpro Application.

Moreover even the function module,

SWO_QWERY_FUNCTION_MODULE is not remote enabled. And anyway, feeding the any other Function Module name as in inout parameter would only retrieve the description of that function module, the status of remote enable property and Free Date, which can hardly be of any use to you.

Hope your query is well addressed.

Regards,

Tushar Sinha

former_member222860
Active Contributor
0 Kudos

Here's another RFC Function Module that retrieves the parameters of the BAPI / FM.

RFC_GET_FUNCTION_INTERFACE

Hope it helps you.

Mahesh

Former Member
0 Kudos

Hi P K,

As stated by Mahesh,

RFC_GET_FUNCTION_INTERFACE

is RFC enabled and returns the Import and Export Structure of a specified function module. but it doesnt return you the parameters within the structures.

So you can use,

RFC_GET_STRUCTURE_DEFINITION function module which would return the parameters within a specific structure(table) and other metadata of parameters within.

This way you would be able to retrieve the complete metadata of the import and export structure and the parameters within the structures along with their own metadata.

RFC_GET_TABLE_ENTRIES can help you even get the entries from the table but woud not be a good practice. Select queries would be preferable.

Hopefully, your issue is resolved then.

Regards,

Tushar Sinha

former_member185086
Active Contributor
0 Kudos

Hi

[Follow this| [original link is broken];jsessionid=(J2EE3414900)ID1990530050DB02904298548410356825End#19]

Best Regards

Satish Kumar