Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi guys,
I can't get set expressions working with dates. e.g. Show me only row counts for first day of last month.
The column is calculated as:
Count({<Date={"$(=date(MonthStart(today(),-1)),'DD/MM/YYYY')"}>}ID)
I would expect to see values in the 2nd and 4th row, but instead I see 0 for every row. The date format seems to match (as you can see in KPI indicator). The data model is super simple:
Load
ID,
date(date#(date, 'YYYY-MM-DD'), 'DD/MM/YYYY') as [Date],
date(date#(activation_date, 'YYYY-MM-DD'), 'DD/MM/YYYY') as [Activation Date];
Select
ID,
cast(created as date) as date,
cast(activation_date as date) as activation_date
from table;
What am I doing wrong?
I would try displaying the entire expression to get the first day of the month just to confirm that you are still getting what you expect.
date(MonthStart(today(),-1)),'DD/MM/YYYY')
May be try this
Count({<Date={"$(=Date(MonthStart(Today(), -1), 'DD/MM/YYYY'))"}>} ID)
Hi,
better create a variable for that and use it in the expression.
Regards,
Sadasiva
Error in your expression, ')' is missing for $()
Count({<Date={"$(=date(MonthStart(today(),-1)),'DD/MM/YYYY')"}>}ID)
Change it to below
Count({<Date={"$(=date(MonthStart(today(),-1),'DD/MM/YYYY'))"}>}ID)
Cheating karta hai meri
samjana chahiye na bhai
Hahahaha
Sahi bolta hai tu