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

Function Group with ztable

former_member233090
Active Contributor
0 Likes
516

Hi Experts,

I have a small requirement , i need to create 2 function modules using ztable .

1 function module suppose (z_fungetdetails)

2 function module suppose (z_funupdatedetails)

ztable

field 1

field 2

field 3

field 4 etc

so what i want is :

1) i need to accept the fields from ztable into the function module and get the details from first function module ie z_fungetdetails

so actually iam getting confused in taking the parameters ie importing and exporting and the query what i need to ?

2)i need to update or modify the ztable from the second function module ie z_funupdatedetails.

Pls help.

Bhavana

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
429

Hi Bhawna,

Please go through below link to get understanding of FM

http://help.sap.com/saphelp_nw04/helpdata/en/26/64f623fa8911d386e70000e82011b8/content.htm

Further , you need to decide clearly what should be the import and export parameters of the FM , or parameters should be passed as Tables.

Create FM and then write your logic in it.

Hope this helps you.

2 REPLIES 2
Read only

Former Member
0 Likes
430

Hi Bhawna,

Please go through below link to get understanding of FM

http://help.sap.com/saphelp_nw04/helpdata/en/26/64f623fa8911d386e70000e82011b8/content.htm

Further , you need to decide clearly what should be the import and export parameters of the FM , or parameters should be passed as Tables.

Create FM and then write your logic in it.

Hope this helps you.

Read only

Former Member
0 Likes
429

Hi Bhavan,

1. z_fungetdetails

THis should have import parameters same as the primary key of the tables.

Then write a select query

Select * from ZTABLE into GT_TABLE where

matnr = im_matnr

....

GT_TABLE would be a parameter in the TABLES tab.

2. z_funupdatedetails

This FM would have only TABLES parameter .. GT_TABLE.

use UPDATE ZTABLE2 using GT_TABLE...

commit work..

Thanks,

Best regards,

Prashant