最新消息:雨落星辰是一个专注网站SEO优化、网站SEO诊断、搜索引擎研究、网络营销推广、网站策划运营及站长类的自媒体原创博客

crystal reports - Check dataset after "next" dataset - Stack Overflow

programmeradmin0浏览0评论

I´ve got a problem with comparing consecutive lines in crystal reports. Here is my scenario, I´ve got the following datasets:

Dataset Positionnumber Positiontext
1 100 Text100
2 105 Text105
3 150 Text150

I´ve got a problem with comparing consecutive lines in crystal reports. Here is my scenario, I´ve got the following datasets:

Dataset Positionnumber Positiontext
1 100 Text100
2 105 Text105
3 150 Text150

It is possible to just have the case with only Dataset 1, Dataset 1 & 2 or Dataset 1 & 2 & 3. If there is more then one dataset available I want to read out the highest dataset. The other datasets are not used then.

Example 1:

Dataset Positionnumber Positiontext
1 100 Text100
2 105 Text105

--> Read out Dataset 2

Example 2:

Dataset Positionnumber Positiontext
1 100 Text100
2 105 Text105
3 150 Text150

--> Read out Dataset 3

I already tried the "next"-function but that only helps with looking for Dataset 2, I can´t reach and compare Dataset 3:

if {Z_QM_INFOSET_CR.VIQMFE-POSNR} < next ({Z_QM_INFOSET_CR.VIQMFE-POSNR}) then next({Z_QM_INFOSET_CR.VIQMFE-BAUTL})

else {Z_QM_INFOSET_CR.VIQMFE-BAUTL}

I hope my problem gets clear and you guys can help me out. Thanks in advance!

Share Improve this question edited Feb 6 at 9:22 felix571 asked Feb 6 at 9:20 felix571felix571 94 bronze badges
Add a comment  | 

1 Answer 1

Reset to default 0

If you want to only show the newest line, you could sort in descending order by "Dataset" and hide all lines that do not have a LineNum = 1.

发布评论

评论列表(0)

  1. 暂无评论