Problems building a hierarchy (with groovy + lookups used beforehand)

      Problems building a hierarchy (with groovy + lookups used beforehand)

      Hi Everyone,

      I´ve got the following problem and hope someone can help
      ?(

      I want to build a dimension with several nodes:

      1. All Objects
      2. Cars / Buildings (to generate this node I use a groovy function in a Field Transform beforehand :

      "if(_input1 < 9000)
      {
      return "Cars";
      }
      else
      return "Buildings";
      whereby _input1 are the bases of my hierarchy.
      3. Red / Blue Cars underneath "Cars" and N.A. underneath "Buildings" (to get this information I use a Lookup in my FieldTransform)
      4. Bases

      What I would the dimension to look like in the end -->
      • All Objects
        • Cars
          • Blue Cars
            • 9000
            • 9002
          • Red Cars
            • 9003
            • ...
        • Buildings
          • N.A.
            • 1000
            • ..
      Using a TreeFH the result is that the bases are not correctly allocated, every base is underneath every third node.
      E.g.
      • All Objects
        • Cars
          • Blue Cars
            • 1000
            • 1002
            • ...
            • 9000

      Thanks in advance for your help! :)


      Post was edited 1 time, last by “Sara” ().