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

Earn the coveted Fabric Analytics Engineer certification. 100% off your exam for a limited time only!

Reply
jlandsm4785
Frequent Visitor

Week Number - A table of multiple values was supplied where a single value was expected

Hello,

 

I am trying to create a table visualization that shows the week number for a date coming a column full of dates.  The best i can do is get one date to appear using either the LASTNONBLANK function, but i cannot get more than one value to show. Instead I get the following error "A table of multiple values was supplied where a single value was expected".  Is the weeknum function unable to cycle through column and produce more than one value?  Any guidance is appreciated, thanks

 

Here is my code to try and produce the table:

 

DateMeasure = CALCULATE(WEEKNUM(ALLNOBLANKROW(ShiftData[WeekEnding]),1))
1 ACCEPTED SOLUTION
v-yiruan-msft
Community Support
Community Support

Hi @jlandsm4785 ,

Do you want to the week number of the field [WeekEnding]? If yes, you can create a calculated column as below to get it:

yingyinr_0-1660811114912.png

Or you can update the formula of your measure [DateMeasure] as below:

DateMeasure = WEEKNUM(MAX(ShiftData[WeekEnding]),1)

yingyinr_1-1660811296675.png

Best Regards

Community Support Team _ Rena
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
v-yiruan-msft
Community Support
Community Support

Hi @jlandsm4785 ,

Do you want to the week number of the field [WeekEnding]? If yes, you can create a calculated column as below to get it:

yingyinr_0-1660811114912.png

Or you can update the formula of your measure [DateMeasure] as below:

DateMeasure = WEEKNUM(MAX(ShiftData[WeekEnding]),1)

yingyinr_1-1660811296675.png

Best Regards

Community Support Team _ Rena
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Seanan
Solution Supplier
Solution Supplier

Hi @jlandsm4785,

Would you be able to provide some example data?

Helpful resources

Announcements
April AMA free

Microsoft Fabric AMA Livestream

Join us Tuesday, April 09, 9:00 – 10:00 AM PST for a live, expert-led Q&A session on all things Microsoft Fabric!

March Fabric Community Update

Fabric Community Update - March 2024

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