Parallel cursor

Answer Posted / cg

Parallel cursor is a technique to overcome loop inside loop technique in abap.
When we have two internal tables , and we have a situation where the entries from first internal table are to be dependant on the second table.
For e.g
Select matnr ernam from mara into table lt_mat where matnr = p_matnr.
Select maktx from makt into table lt_mat1 where matnr = lt_mat.
so for getting maktx we need to wirte first loop for lt_mat and then nested loop for lt_mat1 .
If we write like this , It will take more time to run the program to avoid this we use parallel cursor technique .
E.G select matnr from mara into table lt_mat where matnr = p_matnr.
Select maktx from mara into table lt_mat1 for all entries in lt_mat where matnr = lt_mat
then write loop for 1st select query only and read the second query with read table statment
Loop at lt_mat into lw_mat.
read table lt_mat1 into lw_mat1 where matnr = lw_mat.
endloop.
This is called Parallel cursor technique.

Is This Answer Correct ?    0 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a predefined type in abap?

633


Why is pretty printer user in abap?

633


wat is the difference between A-gate & W-gate?where are they used?

1477


What is an Open Item in SAP? How will you find an Open Item in SAP?

613


What is pakey structure, pshd1 structure and what type of fields it contains? : abap hr

743






singleton class

927


Sal abap on hana interview

701


Does sap handle multiple languages?

552


How to call a subroutine in sapscript?

566


Different types of locks?

623


Can you create an internal table dynamically?(at run time)

1427


What are the client dependant objects in abap / sap?

530


What is the use of buffering?

566


What are the events used in interactive reports?

610


Which transaction code can I used to analyze the performance of ABAP program.?

625