1 Reply Latest reply: Oct 3, 2014 3:57 AM by Elerian Kumpler RSS

    Duplicates in SETNODE/SETLEAF - Structure

    Gerald Stockinger

      Hello,

       

      I am struggling a bit with transforming the GL - Account structure from the SETNODE/SETLEAF/SETHEADER - Structure.

       

      I restricted the SETCLASS to 1 value (= 102) and also the language and the subclass.

       

      For example I have the account 730000 and this seems to be attached to 3 different leafs:

      730000.PNG.png

       

      The correct node is 102/SCL/TR_RE_FAK - according to the SAP - frontend:

      sap_frontend.PNG.png

       

      And it gets worse because this node (102/SCL/TR_RE_FAK) has again two parent elements:

      parentelements.PNG.png

       

      This results in a a profit & loss - report that has a lot of duplicate records in it...

      So I guess I am missing some criteria to filter out the wrong entries.

       

      I also attached my QlikView - script and a sample data extract in Excel.

       

      Any hint will be highly appreciated.

      Thanks in advance!!

       

      BR,

      Gerald

        • Re: Duplicates in SETNODE/SETLEAF - Structure

          Hi Gerald,

           

          I do not know if you are still confronted with this problem,

           

          The issue you have is to extract bottom up, i.e. you are trying to get the SETNODES & SETHEADER for a cost element / account. But SAP allows you to have several groups which contain the same elements (accounts) in parallel, i.e. your account "730000 Transporte durch Dritte" can be part of different parents. Anyhow, the TOP-Parent MUST be different.

           

          The solution is, to select the proper TOP Parent for your B/S and then loop through the SETLEAF where all nodes which do not belong to the top parent are excluded.

           

          1. Load SETHEADER.SETNAME into temp. Table

          2. Join SETNODE.SUBSETNAME

          3. Load SETLEAF.SETNAME and account assignments

          4. JOIN Temps from above.

           

          Now you can use Hierarchy() or Mappings for your B/S.

           

          If you have any questions, please feel free.

           

          Best regards

          Raimund