cancel
Showing results for 
Search instead for 
Did you mean: 

userdefined function

Former Member
0 Kudos

hi,

while creating the userdefined function, i want to know where to use the value, context and container?

could you explain in detail.

regards,

sasi.

Accepted Solutions (0)

Answers (4)

Answers (4)

Former Member
0 Kudos

Hi,

Check this thread

former_member238007
Contributor
0 Kudos

Hi..

While if u need to pass only the arguments where in u will be declaring the return variable inside the function and will be returnig the value but where as when u go with context the argument options itself will change .. there we need to pass arguments as well with Resultlist which is of java type.. that carries the result of the function..

regards

Kishore

Former Member
0 Kudos

Working with Contexts, Queues or Value.

http://help.sap.com/saphelp_nw04/helpdata/en/f8/2857cbc374da48993c8eb7d3c8c87a/content.htm

value -


> is a value for the input parameter. Values will comes one by one.

Queue -


> it is an entire instance of XML message. That means, all the data will come at once.

Context ---> There will be a context change in the coming XML data.

http://help.sap.com/saphelp_nw04/helpdata/en/d2/58cd3b11571962e10000000a11402f/frameset.htm

There are 2 types of UDF - Simple and Advanced.

Simple UDFs uses Value, wherein we can manipulate only one value (input is one String). Therefore a single string is expected as input and the output would also b a single string.

Advanced UDFs uses Context or Queue, where you manipulate many values (input is an array of Strings).

Refer this link:

http://help.sap.com/saphelp_nw04/helpdata/en/40/7b8e40496f6f1de10000000a1550b0/content.htm

Former Member
0 Kudos

Hi,

> value

if you want to write for example a udf that is a special substring function with one input value and one output value.

> context

Input is a complete context for example with boolean values. If you want to know if at least one of them is true then return true else return false.

> queue

Input is the complete queue. For example if you need to create your own context segments.

http://help.sap.com/saphelp_nw04/helpdata/en/f8/2857cbc374da48993c8eb7d3c8c87a/frameset.htm

Regards

Patrick