Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I have a table that has some IF statements I am trying to remove because it loads quite slow sometimes. On lines that are emtpy a "0" comes up and I am trying to remove this. Right now the expressions is:
IF(
Report = Test
IF($(ReportName)_blankrow = 1, ' ', Sum(Expression))
Which produces something like this:
Now if I remove the _blankrow check part it looks like this.
Does anyone have a good suggestion for making it look like the first without using an IF statement in the front end?
Thanks,
Ali
Would you be able to share a sample or may be images of what you are seeing?
See attached
It's strange that it worked here
I mean $(ReportName)_blankrow, but not in my expression... I see you used vRapport... what is the difference here?
I just used a different name for the variable because I translate the scripts usually to English.
Here is the original:
If(Report<>'Hours',
if($(Rapport)_blankrad=1 ,'', Sum({$<$(Rapport)_Traff = {1} >}[Resultat Belopp])/$(B_enhet) )
,
if($(Rapport)_blankrad=1 ,'', Sum({$<$(Rapport)_Traff = {1},_Valutaflagga={'0'} >}Quantity_Act) )
)
If the above is working, this should work too
If(Report<>'Hours',
Pick(RangeSum($(Rapport)_blankrad, 1), Sum({$<$(Rapport)_Traff = {1} >}[Resultat Belopp])/$(B_enhet), ''),
Pick(RangeSum($(Rapport)_blankrad, 1), Sum({$<$(Rapport)_Traff = {1},_Valutaflagga={'0'} >}Quantity_Act), ''))
That worked! Now just implement and test Thanks like always!
Awesome, but do you see any performance improvements?
Took out memory statistics before and will change all expressions in object and check afterwards. Can post results when I have changed all the expressions.
Changing between reports type is going faster now, but there is still performance issue when changing year month etc. There is al link table where YearMonthAccountNr is a key in the general ledger and in the link table and from there Date is linked to the Calendar Table.
Not very intuitive Think it is causing it to perform worse.
May be get rid of the first if statement also....
Pick(RangeSum($(Rapport)_blankrad, 1), RangeSum(
Sum({$<$(Rapport)_Traff = {1}, Report -= {'Hours'}>}[Resultat Belopp])/$(B_enhet),
Sum({$<$(Rapport)_Traff = {1},_Valutaflagga={'0'}, Report *= {'Hours'}>}Quantity_Act)), '')