cancel
Showing results for 
Search instead for 
Did you mean: 

UDF executed first

Former Member
0 Kudos

Guys,

I vaguely remember reading a weblog or forum post on how to make sure that in Message Mapping a given UDF is executed first (before anything else) but I cannot find it now that I need it...

Could you please help me out if you have this info somewhere.

Thanks a lot,

Viktor

Accepted Solutions (1)

Accepted Solutions (1)

moorthy
Active Contributor
0 Kudos

Hi,

Are you looking for debugging option for Mapping with Queue concepts-

if so, have a look into this-

/people/venkat.donela/blog/2005/06/09/introduction-to-queues-in-message-mapping

Regrds,

Moorthy

henrique_pinto
Active Contributor
0 Kudos

I remember this post.

We had concluded that the best option is creating a flag in global variables area that is initiated with true and that is set to false only by the UDF that you wants to execute first. All other UDFs wait until it's false (while loop).

Regards,

Henrique.

bhavesh_kantilal
Active Contributor
0 Kudos

Hi,

This can be done using JAVA section of your message mapping which is available from SP14. Take a look at this blog,

/people/sap.user72/blog/2005/10/01/xi-new-features-in-sp14

Write the code in the INITIALIZATION section of the Java Section of your Message Mapping and it will be executed first.

Regards,

Bhavesh

Answers (3)

Answers (3)

Former Member
0 Kudos

Hi Viktor,

Have your UDF in the very first target element (Top node at Target side), it'll be called first and then followed by the child elements.

For Eg.

MT_SRC----> UDF0 --> -- MT_TRGT

-


Fld1------> UDF1 --> -


TrgtFld1

-


Fld2------> UDF2 --> -


TrgtFld2

-


Fld3------> UDF3 --> -


TrgtFld3

Here the UDF0 will be called first.

Regards,

Ananth

Former Member
0 Kudos

hi,

target element is always executed as the first one in graphical mapping.

regards,

wojtek

former_member206604
Active Contributor
0 Kudos

Hi,

In a message mapping if a UDF need to be executed first then you need to use that UDF in the mapping of the first field. I don't think there is any other way...

Thanks,

Prakash

Former Member
0 Kudos

So is the mapping guaranteed to be done in the order of the fields? That's good enough if true.

Thanks Prakash,

Viktor

former_member206604
Active Contributor
0 Kudos

Hi,

<i>>>>So is the mapping guaranteed to be done in the order of the fields?</i>

I am not sure if I understood correctly..

Yes the it executes in the order..

Thanks,

Prakash