The ultimate Fabric, Power BI, SQL, and AI community-led learning event. Save €200 with code FABCOMM.
Get registeredEnhance your career with this limited time 50% discount on Fabric and Power BI exams. Ends September 15. Request your voucher.
hi Expert
i am trying to extract the quraterly and fiscal data but my qtrly and fiscal data are showing as same. My fiscal year starts from nov-oct.
dax for qtrly:
Current Quarter Closed PIR Fraud Exposure =
Var _gsi= CALCULATE([PIR EXPOSURE],'PIR-Case-POV'[Stage] ="Closed - No Further Action Required")
VAR _maxyear=MAX('Date'[Fiscal Year])
VAR _maxdate=MAX('PIR-Case-POV'[PIRReferralDate])
VAR _mxqtr=ROUNDUP(MONTH(_maxdate)/3,0)
RETURN
CALCULATE(_gsi,'Date'[Fiscal Year]=_maxyear,'Date'[Fiscal Quarter]=_mxqtr)
in this code i am getting the fiscal year data instead of qtrly data. Is there any way to have this qtr dynamic like lets say if we want to have the previous qtr data.
thank you again in advance
@NP755 , try like
// Non standard - Start in Feb,May,Aug,Nov
QTD =
var _max = if(isfiltered('Date'),MAX( 'Date'[Date]) , today())
var _mod = mod(Month(_max),3)
var _min = eomonth(_max,-1* Switch(True(), _mod =2, 1, _mod =1, 3,2))+1
return
CALCULATE([net] ,Filter('Date','Date'[Date]>= _min && 'Date'[Date] <= _max))
this can help
Time Intelligence, DATESMTD, DATESQTD, DATESYTD, Week On Week, Week Till Date, Custom Period on Period,
Custom Period till date: https://youtu.be/aU2aKbnHuWs&t=145s
calendars
https://community.powerbi.com/t5/Community-Blog/Creating-Financial-Calendar-Decoding-Date-and-Calend...
https://medium.com/chandakamit/cheat-sheet-calendar-of-any-standard-month-just-one-variable-apart-5e...
https://amitchandak.medium.com/cheat-sheet-power-query-financial-year-calendar-5ceaacb520f1
DAX Calendar - Standard Calendar, Non-Standard Calendar, 4-4-4 Calendar
https://www.youtube.com/watch?v=IsfCMzjKTQ0&t=145s
User | Count |
---|---|
15 | |
13 | |
9 | |
6 | |
6 |
User | Count |
---|---|
28 | |
18 | |
13 | |
9 | |
5 |