cancel
Showing results for 
Search instead for 
Did you mean: 

** How to deliver multiple files using BPM (From RFC output)

jegathees_waran
Active Participant
0 Kudos

Hi Friends,

I am doing File-RFC-File scenario using BPM. I am using BAPI_SFLIGHT_GETLIST as my RFC (Standard RFC). If we execute this RFC, it will return the results in tables form. Assume that, the inputs to RFC is like below.

FromCountryKey : US

FromCity: NEW YORK

ToCountryKey: DE

ToCity: FRANKFURT.

The outputs from the RFC is like below.

-


26 Entries

-


-


CAR

CONN

FLDATE

AIR

AIR

DEPTIME

SEATSMAX

SEATSOCC

-


|

DL

0106

19.05.2008

JFK

FRA

19:35:00

280

266

UA

3516

20.05.2008

JFK

FRA

16:20:00

380

364

LH

0401

23.05.2008

JFK

FRA

18:30:00

220

209

LH

0401

28.05.2008

JFK

FRA

18:30:00

220

208

UA

3516

28.05.2008

JFK

FRA

16:20:00

380

367

DL

0106

16.06.2008

JFK

FRA

19:35:00

280

261

UA

3516

17.06.2008

JFK

FRA

16:20:00

380

357

LH

0401

20.06.2008

JFK

FRA

18:30:00

220

213

DL

0106

14.07.2008

JFK

FRA

19:35:00

280

1

UA

3516

15.07.2008

JFK

FRA

16:20:00

380

86

LH

0401

18.07.2008

JFK

FRA

18:30:00

220

123

DL

0106

11.08.2008

JFK

FRA

19:35:00

280

56

UA

3516

12.08.2008

JFK

FRA

16:20:00

380

67

LH

0401

15.08.2008

JFK

FRA

18:30:00

220

114

DL

0106

08.09.2008

JFK

FRA

19:35:00

280

0

UA

3516

09.09.2008

JFK

FRA

16:20:00

380

164

LH

0401

12.09.2008

JFK

FRA

18:30:00

220

64

DL

0106

06.10.2008

JFK

FRA

19:35:00

280

80

UA

3516

07.10.2008

JFK

FRA

16:20:00

380

8

LH

0401

10.10.2008

JFK

FRA

18:30:00

220

16

DL

0106

03.11.2008

JFK

FRA

19:35:00

280

11

UA

3516

04.11.2008

JFK

FRA

16:20:00

380

33

LH

0401

07.11.2008

JFK

FRA

18:30:00

220

53

DL

0106

01.12.2008

JFK

FRA

19:35:00

280

0

UA

3516

02.12.2008

JFK

FRA

16:20:00

380

45

LH

0401

05.12.2008

JFK

FRA

18:30:00

220

25

-


|

We need to create output file for each record. In this case, the system should generate 26 output files.

I imported the RFC and created the required interfaces and designed BPM also.

Start --> Receive step --> Synchronous Send --> Asynchronous Send

But, I stuck in how to deliver each record to the output file from BPM.

Any idea, friends. (like using BPM Multi-line option. or 'Receiver From' property in the Send Step)

Kindly help me friends to solve this issue.

Thanking you.

Kind Regards,

Jeg P.

Accepted Solutions (0)

Answers (4)

Answers (4)

samiullah_qureshi
Active Contributor
0 Kudos

Hi

You can do it by creating one another message interface having structure same as your table.

What you have to do is create a mapping in such a way that for each record in table one message(newly created) must be created.

Use that mapping in an interface mapping, remember occurence of target message should be 0..Unbounded both in message mapping and interface mapping.

Now create one single line message and one multiline message in BPM for newly created message.Use transformation step with new interface mapping, mention source(RFC response) and target message(use multiline element of new message) for the transformation step.

Use send step inside a block,set block mode to "forEach", and attach new message to that send step.

Use multiline and single element of new message in the property window of block.

Now your BPM will look like

Start ---> Receiver ---> Synchronous send ---> Transformation ---> Block ---> Async Send(within block)

I think in this way you can implement what you want.

Regards

Sami

Reward points if helpful.

jegathees_waran
Active Participant
0 Kudos

Hi Patrick,

We already done the scenario using that blog. This tells about how to split a message into 2 or more.

But, in our case, we did not know how many outputs will come. In this case, we definitely handle this thru BPM.

Former Member
0 Kudos

Hi Jegatheeswaran,

1) You can use BLOCK with mode EACH.

2) Put your Synchronous Send within BLOCK.

3) And if you want u can collect it in container also.

Regards,

Rohit.

Reward points if useful.

Former Member
0 Kudos

Hi,

should be possible to do it without BPM like described in this blog:

/people/jin.shin/blog/2006/02/07/multi-mapping-without-bpm--yes-it146s-possible

Regards

Patrick