5 Replies Latest reply: Jan 31, 2017 7:49 AM by Sunny Talwar RSS

    Replicate Above function in script

    Rawad Haber

      Dear Community,

       

      I am trying to read the previous Record at any given record and trying to do so in the script.

       

      Now, when I use the the above function in a chart visualization it works fine. But when I try using the Peek() or Previous() functions in the script I get duplicate records.

       

      Desired Result:

      1.PNG

       

       

      What I get using Peek() or Previous() functions with an order by clause:

       

      2.PNG

       

       

      How do I get my desired output using Peek() or Previous()?

       

      Your help would very much appreciated,

      Thank you,

      Rawad