2 Replies Latest reply: Feb 28, 2011 8:37 AM by Rogerio Faria RSS

    Expression based on non associated fields

      I think that this might be simple, but I couldnt solve it.
      I have 2 tables: Orders and Budget.

      Orders:
      OrderDate, OrderMonth, OrderDay, ValueO
      2010-12-30, 12, 30, 1500
      2010-12-31, 12, 31, 2000
      .....

       

      Budget:
      BudgetDate, BugetMonth, BugetDay, ValueB
      2010-12-30, 12, 30, 1500
      2010-12-31, 12, 31, 2000
      2010-12-31, 12, 31, 1000

      ....


       

      Besides those 2, I have a lot more tables, in a way I cannot associate those 2. So the 2 tables are not associated, and I cannot use BudgetDate as OrderDate.

      And the result I am expecting is a table like that:
      Result:
      Day, Month, Orders, Budget
      30, 12, 1500, 1500
      31, 12, 2000, 3000

      Day And Month are dimensions from Orders table. The fields Orders and Budget must be expressions. I was thiking something like that:
      Order = Sum(ValueO)
      Budget= Sum ( {$<BugetMonth=( 'Month Dimension Value' ) and BugetDay=( 'Day Dimension Value' )> ValueB}