Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
ilanbaruch
Specialist
Specialist

period compare

hi all,

i'm trying to compare between two periods in the same strait table,

user selection based on a floating field (numeric date field with alias) .

expression based on a variable that holds user selection

vYearMonth=GetFieldSelections(RangeYearMonth)

tried it with:

sum( {$<yearmonth = {'=$(vYearMonth)'} , Year=,Month =  > } Amount)

and

Sum({<Year=, Month=, yearmonth = {"=$(=vYearMonth)"}>}Amount)

and

sum({<Year=, Month=, yearmonth={"$(vYearMonth)"}>}Amount)

but..

non of them work


any ideas?

advanced thanks

1 Solution

Accepted Solutions
sunny_talwar

Do you have single selection or multiple selections in RangeYearMonth? May be try this

Sum({$<yearmonth = P(RangeYearMonth), Year, Month>} Charge)

View solution in original post

3 Replies
sunny_talwar

Do you have single selection or multiple selections in RangeYearMonth? May be try this

Sum({$<yearmonth = P(RangeYearMonth), Year, Month>} Charge)

krishna_2644
Specialist III
Specialist III

try - sum( {$<yearmonth = {"=$(vYearMonth)"} , Year=,Month =  > } Amount) - this works only for 1 selected value.


In variable overview -->

vYearMonth

GetFieldSelections(RangeYearMonth)  (dont put equal sign here)


if there are multiple selections, this doest work.



ilanbaruch
Specialist
Specialist
Author

worked for both, thank you