Skip to main content
Announcements
Introducing a new Enhanced File Management feature in Qlik Cloud! GET THE DETAILS!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

how to get all possible values of a field

Hi,

I have a field and I want to iterate over this field in macro. I tried using getPossibleValues but it gives only the selected values so can anybody please tell me whether there is any function to get all values irrespective of the selection.

Thanks,

1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

A easy solution for it can be,

Suppose you want possible values of Field1 in your macro,

then while loading your script, you can also load an additional field as >>

Field1 as Field2.

Then in macro, you can iterate over Field2 with GetPossibleValue for Field2..

Regards

Nitin

View solution in original post

13 Replies
suresh_rawat
Creator II
Creator II

Hi Kavita,

You can achieve this by set analysis.

For Eg : - Sum({1}Sales) - Represent total sales irrespective of the selection.

Regards

Suresh Rawat

Anonymous
Not applicable
Author

A easy solution for it can be,

Suppose you want possible values of Field1 in your macro,

then while loading your script, you can also load an additional field as >>

Field1 as Field2.

Then in macro, you can iterate over Field2 with GetPossibleValue for Field2..

Regards

Nitin

Anonymous
Not applicable
Author

She want to get values in macro........

Not applicable
Author

Hi Suresh,

Thanks for your reply.

I need to iterate over a field in macro which uses VB script. Whatever you have told is not VB script.

suresh_rawat
Creator II
Creator II

Ok Sir...

It is my mistake while reading a problem...thanks to inform me.

Not applicable
Author

Hi Nitin,

Thanks for your reply.

GetPossibleValue --> I think this will give only the selected values and in my case I'm not selecting any value. And I need to get all values irrespective of their selection.

sanketkhunte
Creator II
Creator II

Hello Kavita,

Can you just tell me : What you actually want to achieve to get all values of field in MACRO ?

Then we may give some better solution for the same.

Thank you.

Sanket

Anonymous
Not applicable
Author

Without selection, it will give all values

Not applicable
Author

Hi Nitin,

I tried and its not giving any value when there is no section.