cancel
Showing results for 
Search instead for 
Did you mean: 

Via "Get variant", in case there are more than 10 variants, get variant selection dialog instantly

Former Member
0 Kudos

Hi,

Regarding the variant selection of some transactions, in my case "qa32", there is a minor issue which I can not solve.

As can be seen from the attached picture "Variant selection with 10 or less variants" (taken from our test system), given the restriction that there were at most 10 variants created in an transaction, the dialog for the variant selection is shown instantly (Step 2.). This is not the case if there are more than 10 variants for a transaction (see attached picture "Variant selection with more than 10 variants"; taken from our productive system) you get a "Find variant" dialog (Step 2.). In oder to find all variants you have to delete your name which is prefilled (Step 3.) and click on "Execute" to get the same result (Step 4.).

As the limit of 10 variants (at least in our systems!) is quite low and in my opinion this search is not really necessary in this case, I was searching for some customisation setting to increase this limit (maybe to 20). Unfortunately I did not find any setting in this regards. Does anybody have any idea how to increase this limit, if possible?

Kind regards,

Michael

Accepted Solutions (1)

Accepted Solutions (1)

Laszlo_B
Active Contributor
0 Kudos

Hello Michael,

the variant display mechanism will be chosen in Function Module RS_VARIANT_CATALOG (or in the program LSVARU03) here:


  ELSEIF SY-TFILL GT C_VARILIST AND POP_UP EQ 'X'

     and sy-binpt is initial. " and sy-uname ne 'KSCHMIDT'.

    CALL SELECTION-SCREEN 100 STARTING AT 10 10

                         USING SELECTION-SET 'SAP&1'.

Where C_VARILIST is a constant with value '10'.

This '10' value determines whether a plain list or the variant catalog will be displayed.

If there are less than 10 (or to be more specific: less than C_VARILIST) elements, the following code will run:


* es sind nicht mehr als c_varilist Varianten vorhanden, Anzeige sofort

* als Liste

    sort variant_table by variant.

    if not sy-binpt is initial." or sy-uname = 'KSCHMIDT'.

      CALL_FLAG = 'X'.

      Call Screen 305 Starting At 02 2

            Ending   At 84 12.

    else.

      perform send_ALV tables variant_table using space.

    endif.

Else the catalog will be shown.

C_VARILIST is set in Include LSVARTOP, so I do not know any standard methods which would allow to override this number.

So this would call for a modification of SAP-standard code, but personally it freaks me out to change such a "near-to-the-core" setting...

Best regards,

Laszlo

jschoetteler
Participant
0 Kudos

There is even a quite old SAP-FAQ-note 540779 for COOIS (with usually many variants), that answers this question 4 with

"You can modify ... Include LSVARTOP, change value of C_VARILIST for example, to '9999' "

Answers (2)

Answers (2)

Former Member
0 Kudos

Hi Laszlo,

Thank you very much for your fast and precise answer. Too bad this can't be changed in an easy way. 😕

Kind regards,

Michael

PS: To be nitpicking: You probably mean "If there are less than 11 (or to be more specific: less or equal than C_VARLIST) elements, [...]". -> 10 elements do not trigger the behaviour yet, as can also be seen by the attached picture "Variant selection with 10 or less variants".

Laszlo_B
Active Contributor
0 Kudos

Hello Michael,

if I had to guess this is "one of those old settings which was created when giant lizards were roaming on the face of the Earth"*, and limits like this seriously helped performance.

I would say this limit could be changed nowadays - until then, if the same values are used in the transaction, perhaps transaction SHD0 can help.

Best regards,

Laszlo

*: I've read this somewhere around SCN, so (C) to whomever it was...

P.S.: Yes, you are right, I meant it that way - it seems I had the "Friday afternoon" effect.

Jelena
Active Contributor
0 Kudos

Great question! As Laszlo already explained, this is pretty much hard-coded.

IMHO this is one of the stupidest designs in SAP. This drives the users nuts (and annoys me personally) all the time. Why does it have to be 10? What's the problem with showing 20, 50 or N variants? That's what scroll bar is for.

And, just like you, we always run into this when we only have a few more. And 99% of the time there is no user-specific variant, so you have to clear the user name field. All it could take is a few lines of code to read the value from system parameter or some such. Ugh, ugh, ugh.

Former Member
0 Kudos

Why oh why did you remind of this stupid thing, just as I was leaving for the day.

Former Member
0 Kudos

KSCHMIDT obviously saw and enjoyed the benefit of it for a while... 🙂

If he had used a GET PARAMETER way back when then it would probably still be there 😞