Qlik Community

QlikView Creating Analytics

Discussion Board for collaboration related to Creating Analytics for QlikView.

Not applicable

How to create flag on summed up field

I have created fields to Flag whether or not there is an Error in a particular field, with 1's and 0's.  What I would like to be able to do, is create a Flag that says which fields have errors in them, that will then update as I filter on Policy's.  Here is an example of what my dataset looks like;

 

PolicyField AField BField C
1010
2000
3000
4110
501

0

I would like to be able to create a Flag so I could have a list box that would show;

Fields with Errors

Field A

Field B

Then if I select policy 1, it would function appropriately to only show Field B.

My final dataset will have 2m+ Policies and 100+ Fields, so I'm looking for a good way of doing this.  The fields I'm comparing may build over time as well, so any way to automate it would be best, though I would take any solution at this point.

Thanks,

1 Solution

Accepted Solutions
MVP
MVP

Re: How to create flag on summed up field

Maybe something like

CROSS:

CROSSTABLE (FieldName, Flag)

LOAD *

FROM YourTableSource;

RESULT:

LOAD Policy, FieldName

RESIDENT CROSS

WHERE Flag = 1;

DROP TABLE CROSS;

The Crosstable Load

3 Replies
MVP
MVP

Re: How to create flag on summed up field

Maybe something like

CROSS:

CROSSTABLE (FieldName, Flag)

LOAD *

FROM YourTableSource;

RESULT:

LOAD Policy, FieldName

RESIDENT CROSS

WHERE Flag = 1;

DROP TABLE CROSS;

The Crosstable Load

effinty2112
Honored Contributor

Re: How to create flag on summed up field

Hi Joe,

               You can make a crosstable like this:

CrossData:

CrossTable(Field, Flag) LOAD * Resident Data; //Where is the dataset you mention

If you add listboxes for Policy, Field and Flag then selecting 1 in Flag will show the policies and the fields where errors reside according to your flags.

cheers

Andrew

Not applicable

Re: How to create flag on summed up field

Thank you both!  This worked perfectly!  Was struggling with this all day.

Community Browser