‎2016 Jun 21 4:35 PM
Hello, I'm using max blocking factor for this query but it seems that is not working correctly, idk if i'm doing it wrong pls help.
SELECT rbukrs docnr ryear segment prctr
INTO TABLE t_faglflexa
FROM faglflexa
FOR ALL ENTRIES IN i_detalle_aux
WHERE rbukrs = i_detalle_aux-bukrs
AND docnr = i_detalle_aux-belnr
AND ryear = i_detalle_aux-gjahr
AND rldnr = '0L'
%_HINTS ORACLE '&MAX_IN_BLOCKING_FACTOR 100&&MAX_BLOCKING_FACTOR 100&'.
I checked in st12 and it's no calling it.
Ty all.
‎2016 Jun 21 5:16 PM
‎2016 Jun 21 5:53 PM
I did it but still it does not appear in st12. Mayb it works but st12 doesn't show that. idk, thx anyway.
‎2016 Jun 21 10:23 PM
Sorry but I just realized, my answer was just out of context!
If you have only one line in I_DETALLE_AUX, then your trace is okay. Note also that it's normal to not see %_HINTS for these SAP specific hints in the SQL trace, because it's executed at SAP side only.
In fact, the question is: what did you expect?
And what do you mean "it's not calling it"?
‎2016 Jun 22 4:06 AM
I mean for example, when I use an index, i go to st12 and I can see the index i'm using in that query, but when I use the max blocking factor I can't see it, so idk if i'm doing it wrong or mayb it's working but st12 doesn't show me that. If u want I can show u some images. ty.
‎2016 Jun 22 7:59 AM
Okay, so your question is more about how it works.
Read the SAP note 634263 (Selects with FOR ALL ENTRIES -> https://service.sap.com/sap/support/notes/634263 ), and the SAP note 48230 (Parameters for the SELECT ... FOR ALL ENTRIES statement -> https://service.sap.com/sap/support/notes/48230 ). The note 634263 explains problems of performance of for all entries, optimization, change of max blocking factor to 1000 since 6.10, and there is an attached PDF document.
In the trace, you'll see in the WHERE of the OPEN operation, a repetition of conditions separated by OR, with a maximum of max_blocking_factor; the number of subsequent FETCH operations corresponds to (approximately) the number of internal table lines divided by the max_blocking_factor.
There are probably a few blog posts too, about the topic.