6 Replies Latest reply: Jan 20, 2012 8:26 AM by terrywloch RSS

    set expression with expression or dimensions

      I've the following problem.
      I want to see the stock day by day of my products, but i do not have historical data.
      I've a table where I've the current stock and another table with the sellings.
      The selling table have 2 fields StockFrom and SellDay.
      StockFrom is even the key field to connecto the selling table with the current stock.


      So now I need to find out the stock at a give day;
      The formula for every day is
      Current stock with StockFrom<Min([given date])
      + Current Stock with StockFrom=[given date]
      + selling with StockFrom=[given date]
      - selling with SellDay=[given date].


      Now.. everything quite easy if you use a Data Island and IFs... but extremly slow in my situation, so I decided to use StockFrom as main date.
      so... evrything easy... until the SellDay = [given date]
      I was thinking to use something like



      TOTAL SellDay)

      but I can't handle it...
      Does someone have an idea of how could it be done?


      Thank you