6 Replies Latest reply: Apr 2, 2014 9:22 AM by Girish Talele RSS

    Peek previous row value if condition is true

    Girish Talele

      Hi,

      I have a sample data as given in below image (column A to D),

      As a result I want Qty2 of previous row (Column E) of same order and where the Key not equals to "Key5".

      Untitled.jpg

      Using Peek() function, I am able to get required results, Results are coming as shown below,

      IF(peek(Order,-1)=Order and Key<>'Key5',peek(Qty2,-1),Qty1)as Previous_QTy2

      Untitled.jpg

      Please suggest is there any way to achieve said results.

       

      Regards,

      Girish.