Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Parallel Processing batch input

Former Member
0 Likes
1,757

hello, i have problem ...

it possible work batch input in parallel processing ? ?

9 REPLIES 9
Read only

matt
Active Contributor
0 Likes
1,197

Technically yes. But it depends on what the transaction is, and how it maintains locking. If two parallel processes try to update the same object at the same time, one will fail, as it couldn't get a lock.

Read only

Former Member
0 Likes
1,197

they come carried out of the insert on the same table, as I can proceed with ?

Read only

Former Member
0 Likes
1,197

me you can write the code with which I can send more sessions parallel than batch inpu

Read only

matt
Active Contributor
0 Likes
1,197

Nicola - don't ask for solutions to problems via email. If we discuss on the forums, all can benefit.

There are many blogs and articles about how to implement parallel processing - use the search function available in SDN. I understand English isn't your first language, but I'm unlikely to be able to make things clearer for you. The SAP help files have very good information - and this might be available in your first language,

matt

Read only

Former Member
0 Likes
1,197

my problem.

have 1 file in input..

open 1 session "batch input"

work file

close session

my new program,

work in parallel multi session "batch input"

you know solution ?

Read only

matt
Active Contributor
0 Likes
1,197

>

> my problem.

> have 1 file in input..

> open 1 session "batch input"

> work file

> close session

>

> my new program,

> work in parallel multi session "batch input"

>

> you know solution ?

This is the solution:

Read the file into an internal table.

Break the file into smaller internal tables.

For each smaller table use CALL FUNCTION STARTING NEW TASK and the principles of parallel processing as described in SAP HELP, blogs and articles on SDN.

The function module is an RFC enabled function module. It has as parameters all the information it needs to create a batch session With the data it has been sent it opens a batch input session.

I cannot write the code for you.

matt

Read only

Former Member
0 Likes
1,197

FORM AGGIORNA.

PERFORM PRELEVA_FILE.

*perform controlli_preliminari.

PERFORM R7000-OPEN-BI. " open sessione batch input

LOOP AT TB_FILE.

REFRESH ALL_TABLES.

CLEAR ALL_TABLES.

PERFORM DETERMINA_TABELLA_COND.

READ TABLE TB_CAMPI WITH KEY CAMPO = 'RV130-SELKZ'.

VN_RIGA = SY-TABIX.

VN_TABIX = SY-TABIX.

PERFORM READ_CAMPO.

READ TABLE ALL_TABLES WITH KEY KOTAB = VA_CAMPO.

IF SY-SUBRC NE 0.

MESSAGE E000 WITH 'Tabella sequenza '

VA_CAMPO 'inesistente'.

ENDIF.

VN_RIGA = SY-TABIX.

PERFORM R7100-CHARGE-TAB-BDC USING:

CA_START_DYNPRO 'SAPMV13A' '0100',

CA_FIELD_DYNPRO 'RV13A-KSCHL' VA_KSCHL,

CA_FIELD_DYNPRO CA_OK_CODE '=ANTA'.

CONCATENATE 'RV130-SELKZ(' VN_RIGA ')' INTO VA_FIELD.

PERFORM R7100-CHARGE-TAB-BDC USING:

CA_START_DYNPRO 'SAPLV14A' '0100',

CA_FIELD_DYNPRO VA_FIELD 'X',

CA_FIELD_DYNPRO CA_OK_CODE '=WEIT'.

CONCATENATE '1' ALL_TABLES-KOTABNR INTO VN_DYNPRO1.

PERFORM ALTRE_VIDEATA USING VN_DYNPRO1.

ENDLOOP.

PERFORM R7010-CLOSE-BI. " Close sessione batch input

MOVE VN_ELAB TO VN_RECELAB.

ENDFORM. " AGGIORNA

Read only

Former Member
0 Likes
1,197

I have not understood, I must create a function and use CALL FUNCTION STARTING NEW TASK, every time I want to call that it in parallel, or CALL FUNCTION STARTING NEW TASK the use on the session of batch input

Read only

matt
Active Contributor
0 Likes
1,197

You MUST go and read and understand the SAP Help about parallel processing. Also try and read some of the blogs about it. At the moment, I'm afraid your basic understanding is not sufficient. This is a relatively advanced ABAP topic.

If, having read the help and the blogs, you still can't do it, then you need to have help, on site, from a senior developer. It is not going to be solved on this forum.

matt