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
Peta_g
Helper I
Helper I

dax banding - calculated column Customers[Age] not being recognised by intellisense

Hi Community

 

I'm learning DAX from @MattAllington 's SuperCharge PBI (p 148) & it's great but I'm having a problem creating the following calc col on Customers in AdventureWorks:

 

AgeGroup = CALCULATE(

    VALUES(AgeBands[Band]),

        FILTER(AgeBands,

            Customers[Age] >= AgeBands[Low]

            && Customers[Age] < AgeBands[High]

        )

)

I'm getting the error: "A single value for column 'Age' in table 'Customers' cannot be determined. This can happen when a measure formula refers to a column that contains many values without specifying an aggregation such as min, max, count, or sum to get a single result."

 

Customers[Age] is not being recognized by intellisense. This is also a calc col (working ok) with the formulae:

Age = ROUNDDOWN((DATE(2003,1,1) - Customers[BirthDate])/365,0) - data type & format: whole no.

 

I've also referred to Marco Russo's https://www.sqlbi.com/articles/grouping-transactions-by-age-of-customers-in-dax/ & am having the same problem.

 

thanks for any advice.

Peta

 

1 ACCEPTED SOLUTION

You are right Cherie, however I also provide support to anyone that purchases my book and has problems with the exercise.  


Peta, you have written you "column" as a measure instead of a column.



* Matt is an 8 times Microsoft MVP (Power BI) and author of the Power BI Book Supercharge Power BI.

View solution in original post

13 REPLIES 13

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.