Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi i have this problem, i have a variable like this:
Let vFineMonthContrAltAnnoTempoMinMonth = 'MonthEnd(MakeDate(GetFieldSelections(ANNOTEMPO),Month(Date(Date#(rangemin(' & '$' & '(=GetFieldSelections(MESETEMPO))),''MM'')))))';
this variabile have for value the last day of the "min" month i choose; for example from my selection MESETEMPO i choose 1,2,3
it will be 31/01/2018
is all ok till i choose 6 months (mesetempo = 1,2,3,4,5,6)
but if i choose 7 months i see mesetempo will be NOT 8,9,10,11,12
so my variable not do the correct value.
is possible to say to qlikview to make a right selection withouth this NOT
so if i choose 7 momnths in mesetempo, i want see 1,2,3,4,5,6,7
and so on
?
thanks
You put the 12 within the fourth parameter which is for state-name and the second-parameter for the delimiter isn't a comma. Try it instead with:
GetFieldSelections(MESETEMPO, ',',12)
- Marcus
You need to add a max_values argument to the GetFieldSelections function and set it to at least 12.
From QV Help:
Syntax:
GetFieldSelections ( field_name [, value_sep [, max_values]])
Return data type: string
Arguments:
Arguments | Description |
---|---|
field_name | The field containing the range of data to be measured. |
value_sep | The separator to be put between field values. The default is ', '. |
max_values | The maximum number of field values to be individually listed. When a larger number of values is selected, the format 'x of y values' will be used instead. The default is 6. |
But the problem isn't in the set analisys, the function is right work, the problem is when i choose more than 7 values in my list, when i choose more than 7 values QlikView write in "current selections": MESETEMPO = NOT 8,9,10,11,12
but i need : MESETEMPO: 1,2,3,4,5,6,7
is possible to say to qlikview to make a right selection withouth this NOT?
thanks
Like mwoolf hinted you need to specify the second/third parameter of the getfieldselections(), too to be able to change this behaviour. Also you could change the used default-number within the user-properties, see: Re: Current Selection Box in Access Point only shows 6 Values.
- Marcus
ok thanks, i changed the used defautl-number, and now is ok i see the current selection: 1,2,3,4,5,6,7...,12
but i see my set analisys not work correctly:
'MonthEnd(MakeDate(GetFieldSelections(ANNOTEMPO),Month(Date(Date#(rangemin(' & '$' & '(=GetFieldSelections(MESETEMPO))),''MM'')))))';
it work good till 6 values choose, but after the 7th it not work...
becouse if i use: GetFieldSelections(MESETEMPO,",",12)
in my set analisys it NOT work
You put the 12 within the fourth parameter which is for state-name and the second-parameter for the delimiter isn't a comma. Try it instead with:
GetFieldSelections(MESETEMPO, ',',12)
- Marcus