If I have nested start expressions in a template, does the THISROW expression change to the the row selected in the start expression once it hasnโt reached the END expression or does it always refer to the row that triggered the template?
For example in the below, does the _THISROW in the second start expression refer to โProjectDetailsโ row selected or the same row that the _THISROW in the first start statement points?
<<Start: Filter("ProjectDetails", [StartDate] > [_THISROW].[Date])>>
........
<<Start: Filter("ProjectActivities", [ProjectID#] = [_THISROW].[Project Name])>>
........
<<End>>
<<End>>
Solved! Go to Solution.
Hello @Cathal_Noone, first let me show you the best explanation there is for [_THISROW], it applies to both regular expressions and workflows.
By looking at the masterfully explained diagram, we can see that [_THISROW] is always going to refer to the origin row.
Hello @Cathal_Noone, first let me show you the best explanation there is for [_THISROW], it applies to both regular expressions and workflows.
By looking at the masterfully explained diagram, we can see that [_THISROW] is always going to refer to the origin row.
Thanks a million @Rafael_ANEIC-PY, that is exactly what I was looking for.
Iโm facing the same and I know I could resolve by introducing a new VC that can be consumed by the nested Start but I would rather avoid that if possible.
So Iโm curious how you solved this problem?
If you have a look at Rafaels post the solution is in the attached FAQ. Essentially, use [_THISROW-1] to go up one level to the previous start, [_THISROW-2] to go up 2 levels, etcโฆ
Ah, I didnโt quite gather thatโs what you needed. I have a different need. Iโll continue searching and open a Question if I canโt find the answer. Thank you for the response.
For some strange reason, my problem was solved by using [_THISROW-1]. Let me explain my scenario:
I was looking for getting a running total in my email template and I didn't want to use Virtual Columns for getting running totals as it cripples the loading time. My data was sorted in reverse chronological order, hence all I had to do is to filter the rows that are before the current row and take the sum. I was frustrated with [_THISROW] and after reading this post I realized that it is not going to work. I expermented with [_THISROW-1] and it gave me the desired result.
User | Count |
---|---|
61 | |
25 | |
14 | |
11 | |
6 |