1 Reply Latest reply: Sep 19, 2011 11:48 AM by Marc Livingston RSS

    Selection Box - Choosing between AND/OR

      Hi all,


         I have a simple selection box, and inside the selection box when one chooses more than one option, QlikView automatically applies an OR function. How to change the behaviour to an AND function?




        • Re: Selection Box - Choosing between AND/OR

          Taken from Help section of Qlikview:




          And-mode in List Boxes

          A multiple selection within a field is by default interpreted as logical OR, which means that data associated to any of the selected field values will be shown in other fields. It is however possible to set certain list boxes to AND-mode instead. When you make multiple selections in a list box set to AND-mode, the associations in other fields must be to all selected values, which is exactly how associations are normally made to multiple selections in several fields.

          When AND-mode is activated, an ampersand ("&") will be displayed in front of selected values.

          If you click and hold a value for a moment, the selection will switch from (AND) selected (green) to NOT selected (red). The ampersand will also be replaced by an exclamation mark ("!"). The NOT selection which is a forced exclusion of the value or values so marked, can only be made when a list box is in AND-mode.



          A field cannot always be set to logical and mode. The reason for this is that the and alternative is logically meaningful only if the concerned field is linked to only one other field.

          The AND-mode option is only allowed under very strict conditions, imposed by the theory behind the QlikView logic. In order to be used in AND-mode, the following criteria must be fulfilled:

            • the field must only exist in one logical table,
            • the field must be the second column of no more than two columns, and
            • the table must not contain any duplicate records, and
            • the table must be loaded using a distinct qualifier. If the table is loaded using a Select statement, you must use a preceding Load distinct *.