Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik and ServiceNow Partner to Bring Trusted Enterprise Context into AI-Powered Workflows. Learn More!
cancel
Showing results for 
Search instead for 
Did you mean: 
pgloc2020
Creator
Creator

How to display the current remaining/ending balance only.

Hello All,

I have a scenario where I have to display only the current ending balance for a company. I do not want to display the previous payments made by the companies. For example - 

I have a data with the following columns-

BALANCE AMOUNT_PAID END_BALANCE ACCOUNT_NAME RECEIPT_DATE
109400 65 109335 ABC Publishing Group, Inc. 10-Feb-23
109335 65 109270 ABC Publishing Group, Inc. 10-Feb-23
109270 65 109205 ABC Publishing Group, Inc. 10-Feb-23
110115 65 110050 ABC Publishing Group, Inc. 10-Feb-23
110050 65 109985 ABC Publishing Group, Inc. 10-Feb-23
109985 65 109920 ABC Publishing Group, Inc. 10-Feb-23
109920 65 109855 ABC Publishing Group, Inc. 10-Feb-23
109855 65 109790 ABC Publishing Group, Inc. 10-Feb-23
109790 65 109725 ABC Publishing Group, Inc. 10-Feb-23
109725 65 109660 ABC Publishing Group, Inc. 10-Feb-23
109660 65 109595 ABC Publishing Group, Inc. 10-Feb-23
109595 65 109530 ABC Publishing Group, Inc. 10-Feb-23
109530 65 109465 ABC Publishing Group, Inc. 10-Feb-23
109465 65 109400 ABC Publishing Group, Inc. 10-Feb-23
110180 65 110115 ABC Publishing Group, Inc. 10-Feb-23
109205 325 108880 ABC Publishing Group, Inc. 10-Feb-23

 

In above scenario, I just want to display amount 10880 as an ending balance for ABC Pub Group. 

Please let me know how I can achieve that?

Thanks!

 

Labels (3)
1 Solution

Accepted Solutions
Oleg_Troyansky
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

Since you have multiple transactions per day, you need a full Timestamp field. If you have one, then you can simply use FirstSortedValue, something like this:

= FirstSortedValue(Balance, -Timestamp)

Using minus in front of the timestamp gives you the last value rather than the first.

Cheers.

Ask me about Qlik Sense Expert Class!

View solution in original post

2 Replies
Oleg_Troyansky
Partner Ambassador/MVP
Partner Ambassador/MVP

Hi,

Since you have multiple transactions per day, you need a full Timestamp field. If you have one, then you can simply use FirstSortedValue, something like this:

= FirstSortedValue(Balance, -Timestamp)

Using minus in front of the timestamp gives you the last value rather than the first.

Cheers.

Ask me about Qlik Sense Expert Class!
pgloc2020
Creator
Creator
Author

It works after adding a timestamp . Thanks