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

Next up in the FabCon + SQLCon recap series: The roadmap for Microsoft SQL and Maximizing Developer experiences in Fabric. All sessions are available on-demand after the live show. Register now

Reply
MAG_PRG
Regular Visitor

Weeknum function error - can't get ISO week

From all the documentation I have seen, this DAX code should give me the ISO week number for today:

Week = WEEKNUM(Today(), 21)

But this is giving me an error, saying 21 is not the correct parameter type. When it gives me the available options, only 1 and 2 appear:

MAG_PRG_0-1687243876954.png


The documentation here seems to clearly state that 21 is a valid option for return_type:
https://learn.microsoft.com/en-us/dax/weeknum-function-dax

Does anyone know why it will not accept 21 as the parameter?

1 ACCEPTED SOLUTION
Anonymous
Not applicable

Hi  @MAG_PRG ,

 

According to research, a similar issue has been reported internally.

I will update here once I get any information.

 

Best Regards,

Liu Yang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

2 REPLIES 2
Anonymous
Not applicable

Hi  @MAG_PRG ,

 

According to research, a similar issue has been reported internally.

I will update here once I get any information.

 

Best Regards,

Liu Yang

If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

jk13
Frequent Visitor

I have the same issue with my existing WEEKNUM function!

WEEKNUM(TODAY(),2) is giving me since yesterday also the "Parameter is not the correct type" error breaking many reports..

Helpful resources

Announcements
New to Fabric survey Carousel

New to Fabric Survey

If you have recently started exploring Fabric, we'd love to hear how it's going. Your feedback can help with product improvements.

Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.