Qlik Community

Ask a Question

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
Join this live chat April 6, 10AM EST - QlikView to Qlik Sense REGISTER
cancel
Showing results for 
Search instead for 
Did you mean: 
karimeddini_sla
Contributor III
Contributor III

Indirect Set Analysis w/ Prev/Next ID

Hi, I am trying to get the previous or next value within a group. While the results are correct in aggregate, the #s are not associating with the expected record. For each group, the value in "Next Value" should be associated with the previous row when using this expression SUM({$<id = P(id_next)>} value) . What am I missing (see attached for Load Script)?

EDIT: Though the example uses a table, the application does not (i.e: use of After/Before & Above/Below is not suitable).

13 Replies
karimeddini_sla
Contributor III
Contributor III
Author

It's looking like i'll have to refactor the data model with a bridge table between parent & children (to avoid duplicating the child data). that's really inelegant, though...

martin_dideriks
Partner
Partner

As per my understanding, you wanted row with ID 1 to show the value for ID 2, ID 2 should show the value for ID 3 etc?

If that is the case, please have another look at the expression or the attached file.

The expression does exactly that - it does not need a specific sortorder.

Every value in the Next Value column in the QVW should be 1 row higher than it actually is. I'm trying to have a row dynamically (not in Load Script) get the Value of the next row.

So the below is the table in the QVW. What Iw ant is for "143" to be on the 1st row.

If that is not correct, I dont really understand your requirement.

//Martin

karimeddini_sla
Contributor III
Contributor III
Author

Sorry for being imprecise. I did not distinguish between Table Box & Straight/Picot Table Charts in what I said.

Thank you for your assistance.

karimeddini_sla
Contributor III
Contributor III
Author

That statement wasn't absolutely every aspect of my requirements. It doesn't override what I said before then; it was only to help explain, though I can understand why that might not have been clear. Thank you for your effort.