3 Replies Latest reply: Aug 11, 2011 3:38 AM by liron baram RSS

    Set Expression result changes when using a dimension from a linked table

      Hi all,

       

      I have made a small example of the problem I'm running into:

      This is my script:

      Basis:
      Load * Inline

      [ID, Type, Selectie, Selectie2ID

      0,1,A,1
      1,1,A,1
      2,1,A,1
      3,2,A,1
      4,2,A,1
      5,3,A,1
      5,3,A,1
      5,3,A,1
      5,3,A,1
      6,1,B,2
      7,1,B,2
      8,1,B,2
      9,2,B,2
      10,2,B,2
      11,3,B,2
      12,3,B,2
      13,3,B,2
      14,3,B,2]; 


      det:
      load * inline
      [Selectie2ID, Selectie2Name
      1, A
      2, B];

       

      If I now create a chart where I use set statement to count the number of ID's based on their type and use "Selectie" as a dimension, it works as expected.

      He shows me the amount of ID's that have type 1.

       

      If I change this now and use "Selectie2Name" as a dimension, I would expect the same result. But he shows me a different graph.

       

      The example qvw is attached.

       

      Should there be an expression that works in both graphs or should I search for a different solution in the second graph?

       

      What would be the solution for the second graph and also, why is there a difference ?

       

      Tia !