Skip to Content
1
Jun 10, 2009 at 02:22 PM

The parallel index / cursor and whatsoever solutions

133 Views

I see very often the recommendations for parallel index processing on internal tables,

but I am not convinced by these solutions and I sometimes write that behind these

recommendations (It is about the solution not the person).

The solutions assume usually that every key which is in the first table is also in the

second. This is NEVER true with real data!

There the index must be updated for three cases

+ same key in both tables but different lines

+ table 1 has a line not in table 1

+ table 2 has a line not in table 2

Please provide solution for the general case

itab1 itab2

A A

B

C

D D

If you are done with that please provide the solution for

1:2 relation

and the case

itab

A A 1 and A 2

B B 1

C 1 and C 2

D D 2

I am looking for a faster solution than the standard solution

Functional correctness is absolutely required 😊

itab2 sorted table

LOOP AT itab ASSIGING <fs>.
    LOOP AT sort  ASSIGING <fs> WITH KEY ... = <fs>.
    ....
   ENDLOOP.
ENDLOOP.

Please do not forget to add all costs for sorting if you compare!

Siegfried