9 Replies Latest reply: Nov 8, 2011 4:44 PM by Swarup Malli RSS

    Expression to get the SUM on the First Month...I'm very close

    Roberto Figueroa

      Hi all,


      I'm trying to get an expression to obtain the next:  For each InsumoKey (product) the SUM(TotalPago) in the First Month (MesAnio)


      I think I'm very close with this expressión:


      SUM ( {$<MesAnio = {$(=min(MesAnio))} > } TOTAL <InsumoKey> TotalPago )


      But, obviously, $<MesAnio = {$(=min(MesAnio)) is returning the min(MesAnio) for the whole selection, and I need some expression to get the min(MesAnio) for each InsumoKey.


      You can see this expression in the example below, in the chart column [Total_FirstMonth], and as you can see, it isn't working for the InsumoKey = "ACH-030" I think because their min(MesAnio) is 201104.


      Hope can you help me.


      Best regards,