Store Previous row value for current row in Crysta

2019-06-26 16:12发布

I want to retrieve previous row value in current row just like below (Crystal Report 2008):

+------------+-----------------+----------+------------+----------------+
| Date       | PreviousBalance | Loan     | Collection | CurrentBalance |
+============+=================+==========+============+================|
| 14/02/2012 | 00.00           | 10000.00 | 00.00      | 10,000.00      |
| 15/02/2012 | 10,000.00       | 00.00    | 500.00     | 9,500.00       |
| 16/02/2012 | 9,500.00        | 00.00    | 500.00     | 9,000.00       |
| 18/02/2012 | 9,000.00        | 5,000.00 | 00.00      | 14,000.00      |
+------------+-----------------+----------+------------+----------------+

7条回答
你好瞎i
2楼-- · 2019-06-26 17:06

I think there are a number of ways. How about:

previous({Table.Field})

Or you could have a running total then do {#total} - {Table.Field}?

查看更多
登录 后发表回答