Qlik Community

Qlik Sense App Development

Discussion board where members can learn more about Qlik Sense App Development and Usage.

jyotiranjan
New Contributor

How to find next date value.

Hi,

Please help me by checking the attachments. I put i=0 to 20, but I need the last row to know dynamically for max value of i.

Note: Message was edited by Community Moderator for spelling and clarity

2 Replies

Re: How to find next date value.

Try this may be:

Demo3:

LOAD RowNo() as Key,

  [ClosingBalanceDate],

  [ClosingBalance]

FROM [lib://Desktop/Demo3.csv]

(txt, codepage is 1252, embedded labels, delimiter is ',', msq);

FOR i=0 to FieldValueCount('Key')

  test6:

  Load DISTINCT

  [ClosingBalanceDate],

  [ClosingBalance]as OpeningBalance,

  if(Peek([ClosingBalance],$(i))<>null(),peek([ClosingBalance],$(i+1)),0)as ClosingBalance

  Resident Demo3;

NEXT i

DROP Table Demo3;

jyotiranjan
New Contributor

Re: How to find next date value.

Hi Sunny,

Thanks for your response.But your code is not working for Closing Balance.

But I solved the issue.

Community Browser