cancel
Showing results for 
Search instead for 
Did you mean: 

Message mapping - Field with counter

former_member183906
Active Contributor
0 Kudos

Hi,

I am working on PI7.3 Java stack now.

The requirement is :

There is a field "A" in the target message.

                              Value of field A

For 1st message     PO1

For 2nd message    PO2

For 3rd message     PO3

For 4th message     PO4

Like this the Output need to be increased by 1 for every message.Suppose today 100 message went,so from tomorrow field A value shud start from PO101.So it should always remember what was the last value passed.

Regards

Accepted Solutions (1)

Accepted Solutions (1)

gagandeep_batra
Active Contributor
0 Kudos

Hi,

So you are using PI7.3 Java stack, you can go for File look-up approach also where you need to read the file content every time and update the value after reading.

have lookin the following wiki:

http://wiki.sdn.sap.com/wiki/display/xi/file%2blookup%2bin%2budf?bc=true

Regards

Gagan

Answers (6)

Answers (6)

Former Member
0 Kudos

Hi,

Since you dont have ABAP stack in PI so i would suggest you to maintain number range object in ECC. This is defined using Tcode - SNRO. Where you need to provide Number lengh domain - for e.g. NUM10, if you want your number as 10 digit long.

Create a Z RFC which is in turn calling standard RFC 'Number_Get_Next'. This standard RFC takes parameter as Number Range object created, & Qunatity - which is nothing but increment value which 1 in our case.

Import this ZRFC in PI. Call this in RFC Lookup function. This will return next number than before each time when RFC is called.

Add PO before the result of RFC lookup. This will get you the solution.

Regards,

Ashish

S0003485845
Contributor
0 Kudos

Hi,

in case you have the Seeburger-Adapters available on your PI-System, then this is included as standard functionality

Regards

Stefan

baskar_gopalakrishnan2
Active Contributor
0 Kudos

Use simple JDBC lookup in the mapping to handle this If the sender system accepts and does the same , then you dont need to handle and maintain this.

rajasekhar_reddy14
Active Contributor
0 Kudos

Use below mapping, your team has chage counter value to 0 everyday manually or write some program to do so.

http://scn.sap.com/people/rajasekhar.reddy14/blog/2012/02/15/how-to-maintain-counter-sequence-to-fil...

former_member192851
Active Participant
0 Kudos

Why you cannot make counter on Sender side? And then use it to make PO<counter value> items?

iaki_vila
Active Contributor
0 Kudos

Hi,

With only java stack is a bit complicated to mantain a counter through different messages. I don't really know if that PI version has an extra utility, to start i would use an external DB to store that value or if you have an SAP ERP involved i would use a counter (Z table) from there.

Regards,