Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi, I wonder, why my expression not working.
Its good only with no selections:
When I chose date its 0, I would like it to show the sum result for the current date minus 2 days
My expresion:
Sum({<Data={"$(= date((Max(Data)-2)))"}>} stan_wartosc)
My code in Data Load Editor look like this:
NoConcatenate
Stan_Wartosc_2:
Load
date(floor(Data)) as Data,
hid_dossier_ges,
hid_artykul_ges,
sum(stan_wartosc) as stan_wartosc
Resident Stan_Wartosc
Group By
Data,
hid_dossier_ges,
hid_artykul_ges
;
Drop Table Stan_Wartosc;
It is your selection in your calculated dimension "=(Data)" that is causing you your problem. This dimension is not the same as "Data". So you are performing a set modifier on the field Data while having a selection on "=(Data)".
Try changing your dimension from being a calculated one using "=(Data)" to just use the field "Data".
It is your selection in your calculated dimension "=(Data)" that is causing you your problem. This dimension is not the same as "Data". So you are performing a set modifier on the field Data while having a selection on "=(Data)".
Try changing your dimension from being a calculated one using "=(Data)" to just use the field "Data".
check in your expression editor what values it is evaluating
Send screenshot of it. Also check date format in script.
Regards,
Prashant Sangle
I where able to recreate your issue on my own desktop client. See screenshots
@Vegar Thank you very much, "stupid" typo, and I spent 4 hours on it today.
Yes there is a difference between Data and (Data) - now I will know 🙂
Btw, I tested it on Excel files, new applications, old ones and I was already tearing my hair out "because I've done it X times and it always worked..."
Hey @Sebastian_Dec hope you are well man!
I will just add this that you may want to change your master dimension and remove from it "=" sign s there is not point creating it as =(Data)
you could have just straight up field reference!
EDIT - @Vegar already mentioned that below which i missed. sorry!
Hi @Lech_Miszkiewicz , thanks for replay, all is good 🙂
I quickly changed the copied sheet with filters =Month(Data) and instead of leaving just 'Data', I only removed 'Month', so it ended up as =(Data). This is actually the first time something like this happened to me 😛
As a good practice you also dont want to have =Month(Data) and instead it is so much better to just do that in script Month(Data) as Miesiąc, - you know what I mean.
cheers