Hitachi Vantara Pentaho Community Forums
Results 1 to 2 of 2

Thread: "Dependency level" in function not working?

  1. #1

    Default "Dependency level" in function not working?

    Hi, I've got an issue with a report.

    I've created a report and It might have a problem handling the "dependency level" property of a function.
    What I want to do is a kind of conditional Sum that only adds up values for only every first row of the defined group (In the example attached report that group is called "Order").
    Since I couldn't find a "Conditional Sum" function I handled it with three functions. One to calculate the row number within the group, another one to set a value just to the first row (otherwise set 0), and the other one to make the sum of them.
    That Sum return "77" and it should be "122". I realized that it's adding 28 and 49, and it should be 27, 20, 41 y 34. If I change the condition in the function "first_row_value" to "=IF([row_number_in_order] = 0;[QUANTITYORDERED];0)" then Sum returns 122. So I guess PRD could be having troubles with dependency level.

    It's not that simple to explain it by words, ha.. Hope the attached example helps to clear things up.

    If someone could help me it would be great!
    Attached Files Attached Files
    Last edited by leandrob; 06-27-2013 at 09:48 AM.

  2. #2

    Default

    Obviously that report is not much useful, it's just an example. What I need to do is a report that shows every detail row of each receipt. There are usually more than one row per receipt and in every row there's a common value for "taxes" which is repeated for each receipt row.


    Product ----- Quantity ----- Taxes(for the whole receipt)
    Row1_1stReceipt X Y ZZ
    Row2_1stReceipt U I ZZ
    Row3_1stReceipt J K ZZ
    Row1_2ndReceipt L M OO
    ........

    Then I want to get the Sum of all taxes. So I have to add only one value per receipt because it's the same for every row. In this case Total Taxes = ZZ + OO.
    If it's not possible to define priorities to the functions excecution, is there any other approach to acomplish this?

    Thanks in advance!

Tags for this Thread

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •  
Privacy Policy | Legal Notices | Safe Harbor Privacy Policy

Copyright © 2005 - 2019 Hitachi Vantara Corporation. All Rights Reserved.