Hi,
I'm working on a app to calculate and monitor energy consumption of various buildings.
I'm facing some troubles to get the previous value of energy related to a specific building (I trying to get the column Last One).
Here is the expression I was trying :
INDEX(
SORT(
SELECT
(
Indexs[Index total];
AND(
[Date] = [_THISROW].[Date];
[ID Batiments] = [_THISROW].[ID Batiments];
[ID Energie] = [_THISROW].[ID Energie]
)
);
TRUE ); 1
)
But I'm only getting the actual "Index total", is it a way to get the previous one ?
thanks to any help 🙂
Solved! Go to Solution.
I understand, try this expression then:
INDEX(
SORT(
SELECT
(
Indexs[Index total],
AND(
[Date] < [_THISROW].[Date],
[ID Batiments] = [_THISROW].[ID Batiments],
[ID Energie] = [_THISROW].[ID Energie]
)
),
TRUE ), 1
)
Hello @VictorB, yes, there is, your expression is 99% correct actually, just change [Index total] for [Last one] in your expression.
INDEX(
SORT(
SELECT
(
Indexs[Last one];
AND(
[Date] = [_THISROW].[Date];
[ID Batiments] = [_THISROW].[ID Batiments];
[ID Energie] = [_THISROW].[ID Energie]
)
);
TRUE ); 1
)
It's not working, the column [Last one] is where i'm typing the expression.
I understand, try this expression then:
INDEX(
SORT(
SELECT
(
Indexs[Index total],
AND(
[Date] < [_THISROW].[Date],
[ID Batiments] = [_THISROW].[ID Batiments],
[ID Energie] = [_THISROW].[ID Energie]
)
),
TRUE ), 1
)
User | Count |
---|---|
32 | |
31 | |
30 | |
19 | |
16 |