Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
Hi All,
I have a problem with my custom date period.
I'm using this:
var _today = today()
Return
union (
addcolumns (
calendar(date(year(_today), month (_today), 1), _today)
,"type", "mtd", "order", 1
),
addcolumns(
calendar(date(year(today),quarter(_today),1), _today)
,"type", "qtd", "order", 2
However, my qtd is not working but my mtd is working. QTD is starting from feb which is not correct.
Thanks for your help.
hi @Ejykso
try like:
Table =
var _today = today()
VAR _quarterstart =
DATE(
YEAR(_today),
(QUARTER(_today)-1)*3+1,
1
)
Return
union (
addcolumns (
calendar(date(year(_today), month (_today), 1), _today),
"type", "mtd",
"order", 1
),
addcolumns(
CALENDAR(_quarterstart, _today),
"type", "qtd",
"order", 2
)
)
it worked like:
it would be easier with Time Intelligence Functions.
Why do you need to union these tables as it looks like they overlap? In any case, here is a way to get a date range from the start of the current quarter.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.
User | Count |
---|---|
19 | |
12 | |
11 | |
10 | |
6 |
User | Count |
---|---|
21 | |
20 | |
19 | |
14 | |
10 |