0% found this document useful (0 votes)
20 views

Note 48230 - Parameters For The SELECT ... For ALL ENTRIES Statement

This document describes parameters that can be used to control the SELECT ... FOR ALL ENTRIES statement and their effects. It explains parameters like join_prefer_to_join, join_prefer_union_all, max_blocking_factor that influence how the statement is mapped to the database. The parameters have significant effects and should only be changed with careful consideration and testing.
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
0% found this document useful (0 votes)
20 views

Note 48230 - Parameters For The SELECT ... For ALL ENTRIES Statement

This document describes parameters that can be used to control the SELECT ... FOR ALL ENTRIES statement and their effects. It explains parameters like join_prefer_to_join, join_prefer_union_all, max_blocking_factor that influence how the statement is mapped to the database. The parameters have significant effects and should only be changed with careful consideration and testing.
Copyright
© Attribution Non-Commercial (BY-NC)
We take content rights seriously. If you suspect this is your content, claim it here.
Available Formats
Download as DOC, PDF, TXT or read online on Scribd
You are on page 1/ 5

Note 48230 - Parameters for the SELECT ... FOR ALL ENTRIES statement Vers on !

"ate Pr or t% Cate)or% Pr mar% Com*onent Se&on'ar% Com*onents Symptom Performan&e *ro,(ems o&&/r 0 th the o*en S1L statement 2SELECT ... FOR ALL ENTRIES ...2. Other terms FOR3ALL3ENTRIES Reason and Prerequisites The o*en S1L statement 2SELECT ... FOR ALL ENTRIES ...2 s an A+AP-s*e& f & enhan&ement of the S1L stan'ar'. Th s .ar ant of the SELECT statement a((o0s the A+AP *ro)rammer to 4o n an nterna( *ro)ram ta,(e 0 th one or se.era( 'ata,ase ta,(es. 5For a 'eta (e' 'es&r *t on of that statement t%*e6 refer to the re(e.ant A+AP 'o&/mentat on.7 S n&e there s no s m (ar statement n the S1L stan'ar'6 the o*en S1L statement has to ,e ma**e' from the 'ata,ase nterfa&e of the A+AP en. ronment to one or se.era( semant &a((% e8/ .a(ent SELECT statements that &an ,e *ro&esse' ,% the "+ *(atform. Se.era( *rof (e *arameters a((o0 a 'ef n t on of ho0 the 'ata,ase nterfa&e sho/(' &arr% o/t th s ma** n) 0 th re)ar' to the 'ata,ase. Th s note 'es&r ,es the *arameters that &an ,e /se' to &ontro( the 2SELECT ... FOR ALL ENTRIES2 statement an' the r effe&t. Solution The *arameters ment one' n th s note ha.e &ons 'era,(e effe&ts on most of the &r t &a( 'ata,ase &omman's an' nf(/en&e the *erforman&e of the 0ho(e s%stem to a )reat e9tent. For th s reason6 ,efore &han) n) the *arameters 'es&r ,e' n th s note6 a 'eta (e' *ro,(em ana(%s s ,% e9*er en&e' SAP &ons/(tants or the s/**ort team s re8/ re'. Note n *art &/(ar that &han) n) the *arameters ma% often so(.e a (o&a( *erforman&e *ro,(em6 ,/t t ma% a(so &a/se a st (( , ))er *ro,(em to o&&/r n another *(a&e. For th s reason6 *r or to &han) n) the *rof (e *arameters6 0h &h has a )(o,a( effe&t on a(( statements6 %o/ sho/(' &he&: f rst 0hether the *erforman&e *ro,(em m )ht ,e &a/se' ,% one or t0o *os t ons n the &orres*on' n) a**( &at on that &an ,e &orre&te' ,% a (o&a( &han)e of the &r t &a( S1L statements. The fo((o0 n) *rof (e *arameters are a.a (a,(e;

#4 ! 200$-##-02 Re&ommen'at ons!a'' t ona( nfo Performan&e +C-"+-"+I "+ In'e*en'ent "ata,ase Interfa&e ---IV In.o &e Ver f &at on Summary

rs',!*refer34o n If %o/ set th s *arameter to 2#26 the SELECT ... FOR ALL ENTRIES s m*(emente'

Summary /s n) a 4o n. As of Re(ease <. 006 the *arameter s s/**orte' on(% for the 'ata,ase *(atforms "+= 5"+2 >"+7 an' 2-S S1L Ser.er26 an' t s s/**orte' for Ora&(e as of Re(ease <.#0.

rs',!*refer3/n on3a((

?o/ &an o.err 'e th s *arameter /s n) rs',!*refer34o n @ #. The fo((o0 n) remar:s re(ate to rs',!*refer34o n @ 0. Sett n) th s *arameter to 2#2 )enerates a ( n: n) of ent re statements 0 th >NIONA sett n) t to 202 )enerates an OR ( n: of &on' t ons n the BCERE &(a/se. Ea&h of the ( n:e' *art a( statements!&on' t ons re*resents an entr% of the n*/t ta,(e D ta,E. For e9am*(e; The o*en S1L statement SELECT ... FOR ALL ENTRIES IN ta, BCERE f @ ta,-f. s ma**e' n'e*en'ent of the *arameter rs',!*refer3/n on3a(( to an S1L statement6 0h &h s &ons stent 0 th the stan'ar'; rs',!*refer3/n on3a(( @0 @F SELECT ... BCERE f @ ta,D#E-f OR f @ ta,D2E-f ... OR f @ ta,DNE-f rs',!*refer3/n on3a(( @# @F SELECT ... BCERE f @ ta,D#E-f >NION ALL SELECT ... BCERE f @ ta,D2E-f .... >NION ALL SELECT ... BCERE f @ ta,DNE-f Bhere N s the n/m,er of ro0s n ta,6 an' ta,D E-f s the .a(/e of f e(' f n the -th ta,(e ro0.

rs',!*refer3 n3 ta,3o*t

If th s *arameter s set to 2#26 a statement 0here on(% one f e(' n the BCERE &(a/se 'e*en's on the &on.erte' nterna( ta,(e s ref(e&te' ,% a statement 0 th an IN &(a/se. Co0e.er6

Summary th s s *oss ,(e on(% f the f e(' referen&e an' the BCERE &on' t on are s m*(e eno/)h; essent a((%6 the f e(' referen&e m/st ,e a non-ne)ate' E1 &on' t on. For e9am*(e; If *arameter rs',!*refer3 n3 ta,3o*t s set to 2#26 the o*en S1L statement SELECT ... FOR ALL ENTRIES IN ta, BCERE f @ ta,-f. s ma**e' to the fo((o0 n) S1L statement; SELECT ... BCERE f IN 5 ta,D#E-f6 ta,D2E-f6 ...6 ta,DNE-f7

rs',!ma93,(o&: n)3fa&tor

Th s *arameter s*e& f es an /**er ( m t for the n/m,er of entr es ta:en n from D ta,E to ,e *ro&esse' n one statement. Th s means that f the nterna( ta,(e s*e& f e' n the FOR ALL ENTRIES &(a/se &onta ns more than rs',!ma93,(o&: n)3fa&tor ro0s6 the o*en S1L statement s s*( t nto se.era( statements for the 'ata,ase6 the res/(ts of 0h &h are &o((e&te' n the "+ nterfa&e an' then ret/rne' as an o.era(( res/(t to the A+AP *ro)ram. For an nterna( ta,(e 0 th N ro0s N ! 2rs',!ma93,(o&: n)3fa&tor2 G # n' . '/a( SELECT statements are ss/e' for the 'ata,ase. Co0e.er6 th s *arameter has no effe&t on the ma** n) to IN 5...7 5for *refer3 n3 ta,3o*t7. A'' t ona((%6 the te&hn &a( ma9 m/m ,(o&: n) fa&tor s &a(&/(ate' for ea&h statement6 so that no ( m ts of the 'ata,ase s%stem are e9&ee'e'. If the ( m t of the ,(o&: n) fa&tor s (o0er than ma93,(o&: n)3fa&tor6 the ( m t s /se' m*( & te(%.

rs',!ma93 n3,(o&: n)3fa&tor

Th s *arameter6 s m (ar to rs',!ma93,(o&: n)3fa&tor6 s*e& f es the /**er ( m t for the n/m,er of entr es to ,e *ro&esse' from D ta,E f the &on&rete statement s ma**e' to an IN &(a/se 5see *refer3 n3 ta,3o*t7. Ana(o)o/s(% to rs',!ma93,(o&: n)3fa&tor6 the ( m t of the ,(o&: n) fa&tor s a(so /se' nstea' of rs',!ma93 n3,(o&: n)3fa&tor6 f other0 se the /**er ( m ts of the 'ata,ase s%stem 0o/(' ,e e9&ee'e'.

rs',!*refer3f 93,(o&: n)

If the n/m,er of entr es n D ta,E &annot ,e ' . 'e' ,% ma93,(o&: n)3fa&tor6 (ess entr es 5&on' t ons7 are a((o&ate' to the (ast statement that has ,een )enerate' for *ro&ess n) the 2FOR

Summary ALL ENTRIES2 statement. The res/(t s a ne0 statement. If the same 2FOR ALL ENTRIES2 statement s e9e&/te' .er% fre8/ent(% 0 th a ' fferent n/m,er of entr es n the n*/t ta,(e D ta,E6 ' fferent statements are &reate' /* to the ma9 m/m of ma93,(o&: n)3fa&tor statements. Th s &an ,e a.o 'e' ,% the a,o.e *rof (e *arameter. If th s *arameter s set to 2#26 at most t0o statements of ' fferent (en)th are )enerate'. Th s s a&h e.e' ,% re*eat n) the (ast .a(/e n the n*/t ta,(e as f D ta,E has ,een m*( & t(% f ((e' to the ,(o&: n) fa&tor 5D ta,E s not rea((% mo' f e'7.

rs',!m n3,(o&: n)3fa&tor

If th s *arameter s set to a .a(/e (ar)er than 202 AN" f rs',!*refer3f 93,(o&: n) s set6 2 ' fferent ,(o&: n) fa&tors are /se'; a sma((er 5m n3,(o&: n)3fa&tor7 an' a (ar)er fa&tor 5ma93,(o&: n)3fa&tor7. Co0e.er6 the m n3,(o&: n)3fa&tor s on(% /se' f there are on(% a fe0 entr es n D ta,E; A ( tt(e s m*( f e'6 f the fo((o0 n) a**( es; 2Entr es D ta,E H ma93,(o&: n)3fa&tor ! 22

rs',!m n3 n3,(o&: n)3fa&tor

Th s *arameter 0or:s n &on4/n&t on 0 th rs',!m n3,(o&: n)3fa&tor6 n the &ase that the a'' t on FOR ALL ENTRIES has ,een m*(emente' 0 th an IN &(a/se 5see *refer3 n3 ta,3o*t7. Control over FOR ALL ENTRIES hints >n'er the hea' n) Data ase Inter!a"e #ints6 Note #2$38I 'es&r ,es the o*t ons %o/ ha.e for nf(/en& n) the 'ata,ase nterfa&e ,% enter n) h nts. The h nts are e.a(/ate' n the 'ata,ase nterfa&e tse(f an' are not *asse' on to the 'ata,ase. Start n) 0 th :erne( re(ease 4.=+6 a(( the a,o.e ment one' 2FOR ALL ENTRIES2 *arameters &an ,e set /s n) s/&h a h nt for a s n)(e statement. In the e9am*(e; SELECT J FRO- D..E FOR ALL ENTRIES IN D..E BCERE D..E K3CINTS ORACLE LM*refer3 n3 ta,3o*t #MM*refer3f 93,(o&: n) -#ML. Th s 0a%6 the +oo(ean *arameter L*refer3 n3 ta,3o*tL s e9*( & t(% set an' the +oo(ean *arameter L*refer3f 93,(o&: n)L s set to ts 'efa/(t .a(/e. 2FOR ALL ENTRIES2 h nts6 ( :e h nts6 are )enera((% /se' on(% as a a &orre&t .e 'e. &e n emer)en&% s t/at onsA refer to Note #2$38I. The h nts 'es&r ,e' here sho/(' on(% ,e /se' 0 th &aref/( &ons 'erat on. Related Notes #I00I03 +I 8/ant t% &on.ers on; A&&ess o*t m Nat on #4I=2I# "+=; Com*(e9 S1L statements '/e to man% >NION ALL 0 th FAE #4#<30I "%nam & &han) n) of FAE *arameters #0$#4#$ "+=; Poor Performan&e for 8/er es 0 th FOR ALL ENTRIES

88#083 8=$00= 8#$324 <==34$ =I2=34 =342=3

Related Notes +(o&: n) fa&tors on Ora&(e-,ase' s%stems Com*os te SAP note; ORA-0403# FA1; SAP -a9"+ S1L o*t m Nat on FA1; Ora&(e S1L o*t m Nat on FOR ALL ENTRIES *erforman&e 0 th - &rosoft S1L Ser.er Se(e&ts 0 th FOR ALL ENTRIES

See more at; htt*;!!000.ste&hno.net!sa*-notes.htm(O . e0@sa*noteM '@48230Psthash.nQn>=,/o.'*/f

You might also like