Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
8 years ago
Solved

subtract refunds from purchases

Hi, I need to create a formula that will help me deduct refund amounts from the purchases.  All the transaction amounts are in one column, there is a refund attribute that is tracked in another colum...
  • MattAllington's avatar
    8 years ago

    There are a few ways. Probabaly easiest is to write a measure (or two)

    total raw amount= sum(apprasialaccount(amount)

    total sales =calculate([total raw amount],appraisalaccount[refund]=“False”)

    total refunds = -calculate([total raw amount],appraisalaccount[refund]=“True”)

    total amount = [total sales]+[total refunds]

     

    note the negative sign in front of refunds

  • Anonymous's avatar
    Anonymous
    8 years ago

    All working now, Tanks