cancel
Showing results for 
Search instead for 
Did you mean: 

Supply function Basics needed.

Former Member
0 Kudos
65

Hi Everyone,

I have almost finished my basic tutorials on web dynpro, however am not very clear about the concept of SUPPLY FUNCTION.

Can any one give me some examples to understand it better along with some explanations.

If possible give me more than one example and sample codes which can help me understand this. I did go through the usual examples of SFLIGHT for supply function, however I was not very clear as in why are we using it.

Please help....... Thanks in advance.

Rgds,

Anu .

Accepted Solutions (1)

Accepted Solutions (1)

abhimanyu_lagishetti7
Active Contributor
0 Kudos
Former Member
0 Kudos

Hi Abhi,

The sflight example was not at all clear to me, As in what was the need of doing this. Why have we used supply function here.

what are the other places where we in practical scenarios do need to implem,ent supply function.

thanks in advance,

Anupama.

abhimanyu_lagishetti7
Active Contributor
0 Kudos

The supply function is called by the runtime when the data of the context node is used.

Supply Functions mostly used when you have child nodes, whic his related to a concept called Singleton

http://help.sap.com/saphelp_erp2005/helpdata/en/7a/787e40417c6d1de10000000a1550b0/content.htm

If you have a parent node as VBAK and a Child node as VBAP directly under VBAK, of cardinality both 0..n.

You can have number of sales orders and per one sales order you have number of line items, in this case how do you fill the child node ( items ) which are related one parent element ( one sales order )

If you observe carefully the method parameters when a supply function is created, you can find

PARENT_ELEMENT and NODE

Parent_element represents the parent element for which you are filling the child elements.

Node represents the reference to your child.

hope it is clear.

Abhi

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Anupma,

Please follow the below link:

https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/webcontent/uuid/28113de9-0601-0010-71a3-c8780... [original link is broken]

Follow the tutorial4 in the above link u will get a clear idea on supply function.

Generally supply functions are useful when u want to select particular data and display some information depending on the selected data at the runtime.

Take an example of Flight.

If u want to display the bookings of particular flight at the runtime(selection of particular row of a flights tableat run time) then create subnode for bookings and give the supply function for that node.Here flight node becomes the main node.

Reward points if useful..............

Former Member
0 Kudos

Hi,

u can check all the Tutorials in the Link [Web Dynpro for ABAP: Tutorials for Beginners|https://www.sdn.sap.com/irj/sdn/nw-development?rid=/webcontent/uuid/367b73e5-0901-0010-daa3-9de4771fc985] [original link is broken];.

Regards,

Padmam.