Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
Mohammadwazeri
Helper II
Helper II

How Can I Create Current Quarter, Next Quarter, & Next two Quarters Fields?

Hi,

I need to get the answer for this ASAP.

I stuck in creating current, next, & next tow quarter fields in powerbi desktop, could you please give me an idea how to create these fields using dax or any other way in powerbi.

 

Thanks

Mohammad

1 ACCEPTED SOLUTION
negi007
Community Champion
Community Champion

@Mohammadwazeri  in this case, you can follow the below approach to create 3 measures

 

1. 

current qtr =
var cqtr = QUARTER(TODAY())
var cyear= YEAR(TODAY())
var curr = cyear & "Q" & cqtr
return
curr
 
2.
next1 qtr =
var cqtr = QUARTER(TODAY())
var cyear= YEAR(TODAY())
var next1 = IF(cqtr=4, cyear+1 & "Q1", cyear & "Q" & cqtr+1)
return
next1
 
3.
next2 qtr =
var cqtr = QUARTER(TODAY())
var cyear= YEAR(TODAY())
var next2 = IF(cqtr>=3, cyear+1 & "Q1", cyear & "Q" & cqtr+1)
return
next2
 
 
negi007_0-1632754654436.png

 

i hope it helps you




Did I answer your question? Mark my post as a solution!
Appreciate your Kudos



Proud to be a Super User!


Follow me on linkedin

View solution in original post

2 REPLIES 2
Mohammadwazeri
Helper II
Helper II

Thank you so much, it's working.

negi007
Community Champion
Community Champion

@Mohammadwazeri  in this case, you can follow the below approach to create 3 measures

 

1. 

current qtr =
var cqtr = QUARTER(TODAY())
var cyear= YEAR(TODAY())
var curr = cyear & "Q" & cqtr
return
curr
 
2.
next1 qtr =
var cqtr = QUARTER(TODAY())
var cyear= YEAR(TODAY())
var next1 = IF(cqtr=4, cyear+1 & "Q1", cyear & "Q" & cqtr+1)
return
next1
 
3.
next2 qtr =
var cqtr = QUARTER(TODAY())
var cyear= YEAR(TODAY())
var next2 = IF(cqtr>=3, cyear+1 & "Q1", cyear & "Q" & cqtr+1)
return
next2
 
 
negi007_0-1632754654436.png

 

i hope it helps you




Did I answer your question? Mark my post as a solution!
Appreciate your Kudos



Proud to be a Super User!


Follow me on linkedin

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.