cancel
Showing results for 
Search instead for 
Did you mean: 

Advice on SAP PO 7.4

Former Member
0 Kudos

Hi Guys,

Can somebody please suggest.

HTTP ---> PO ---> IDO

Basically, I am working on a pilot project where they want to replace seeburger with SAP PO but the problem is that they have a custom program written in ECC by 3rd Party which does alot of checks and validation before creating a Sales Order and posting the iDoc in ECC.

They want PO to include all that logic either by RFC Calls or by storing the data in the PO tables during runtime and not permanently and transform the target IDOC mapping and pass the IDoc to SAP but as far as I know it is not possible for PO to hold any business functionality.

It is also not good practice to make multiple RFC Calls for one interface because the xml will contain "n" of records and I have to make "n" numbers of RFC call unless PO can store the values at runtime which I believe is not possible.

There is a possiblity of using BPM but again that will reduce the interface performance and also cause alot of other issue.

I have already suggested them that we can use iDoc user exit and put all the checks and validation over there and PO will just pass the IDoc after mapping to ECC but they are not happy with this approach so can somebody please send me any document or anything which I can show it to them that PO cannot do these because it is a middleware which does transformation and cannot hold the values or business logic.

Kindly suggest.

Many Thanks,

Asif

Accepted Solutions (1)

Accepted Solutions (1)

engswee
Active Contributor
0 Kudos

Hi Asif

I would agree that the approach to have all the business logic in PO is not a good idea. There will be no separation of integration logic and business logic, and it can get pretty messy.

You can try to search around regarding business logic vs integration logic, here are some examples:


As general recommendation IT landscape with both business applications and integration platforms/middlewares

  • No business logic into the integration platform!
  • No integration logic into the business applications!

Business logic should be best handled in the backend system. One of the options is to have the Application Interface Framework (AIF) which is a very robust framework, however it requires additional licensing.

For my previous project, we used a custom IDoc framework instead which replaces the need to use IDoc user exits for validation and substitution. You can read further about that approach in the following blogs, which also includes the source code for implementing the framework.

Rgds

Eng Swee

Former Member
0 Kudos

Many thanks for your quick reply Eng.

Can you please also let me know if PO has any capibility like ABAP to store the internal table at runtime.

Also can we store the value in PI mapping after RFC lookup until we transform the target mapping.

Example

In one RFC call can we pass and return multiple values.

10                                     99 

20      --->RFC Lookup ----> 55

30                                     44     

99 ----> target mapping field 1

55 ----> target mapping field 1

66 ----> target mapping field 1

engswee
Active Contributor
0 Kudos

Asif

As mentioned in the other thread by you, please edit your message and remove your private address. Any queries you have, please just put it in a thread.

Regarding your question, you can store values in graphical variables. The graphical variable can be reused in other target field mapping.

Rgds

Eng Swee

Former Member
0 Kudos

Thanks Eng but I don't think it will solve my problem because if the RFC will return 4 values per content then how would I store that in variable and then how to pass that information to target mapping.

Example

10 -----> RFC Lookup ----> 12

20                                    98

                                       40

                                       abcd

                                     --------------

                                        88                                
                                        33

                                        22

                                       wxyz

12 ----> field1 of IDoc1

98 ----> field2 of IDoc1

40 ----> field3 of IDoc1

abcd ---> field4 of IDoc1

88 ----> field1 of IDoc2

33 ----> field2 of IDoc2

22 ----> field3 of IDoc2

wxyz ---> field4 of IDoc2

engswee
Active Contributor
0 Kudos

The graphical variable behaves in the same way as a normal target field - it can store more than 1 value as the different values can be separated by contexts.

If you are not familiar, I suggest you to try it out first before saying it does not work.

If you want something that you can concretely provide to your client, I suggest you actually do a Proof-Of-Concept (POC) interface. Otherwise, it can get pretty pointless if we just go back and forth debating theoretical concepts without any actual development.

Former Member
0 Kudos

Thanks Eng will try before providing any definite answer.

The thing is that there is no standard Functional Module avaliable which I can use to fetch the information and play around but will play around with the standard message mapping and see if I will get the desired output.

I just wanted to check wether or not it is possible because if somebody has already tried this without the luck then there is no point of putting and wasting the effort.


engswee
Active Contributor
0 Kudos

Asif,

There is a treasure trove of information on SCN if only you take some time to search.

For example, searching on RFC Lookup, you can find the below blog detailing how to optimize RFC calls with multiple value.

If you haven't already, I suggest you check out the following link.

How to use SCN search

Rgds

Eng Swee

Former Member
0 Kudos

Thanks Eng

I have already checked Shabarish blog but the thing is that we have to used around 6 - 8 RFC lookups to fetch the information because customer, material, SKU, Partner etc informations are stored in different FM so from performance prospective it is not the best approach.

Thanks for all your earlier documents as it really help me convenice the client.

BTW I know how to search on SDN I didn't find anything specific and hence the reason I have posted the discussion.

engswee
Active Contributor
0 Kudos

You are welcome. I really won't suggest doing such RFC Lookups (you can see my reasoning here ) But I do understand that sometimes the client needs some convincing first. All the best in your pilot project.

If all your queries regarding this matter has been addressed, please do close the thread to help keep the PI space tidy.

Former Member
0 Kudos

Thanks for all your help. I will close the thread now.

markangelo_dihiansan
Active Contributor
0 Kudos

Hi Asif,

If the client won't change their mind. The best that you can do is optimize your rfc to use a single call as said and then you can use hashmap to build your table.

This can be easily done by going to the Functions tab in your message mapping under Attributes and Methods e.g:

And then under init

And then create two more methods that will set the value and get the value on the hashmap.

The only drawback is this could only be tested via test tab.

Regards,

Mark

Former Member
0 Kudos

Thanks Mark for the valuable information but could you please share some more information about this as this is something new to me.

I am still thinking if we go with this approach then still ABAPER has to write multiple function module or until and unless he will write one generic FM which takes multiple input and return multiple output but I have already checked with him and he said it is not possible so in my scenario I have to atleast call 6 RFC per message and store the output which could be between 10 - 100.

So do you think it is fesible to store 100+ values in the hashmap?

Example

1 RFC for SKU

1 RFC for Customer

1 RFC for duplication

1 RFC for JAN code

and so on...

markangelo_dihiansan
Active Contributor
0 Kudos

Hi Asif,

Yes it would work just design the rfc such that it will only retrieve the values needed.

Regards,

Mark

Answers (0)