Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
I created a calculated column on TableA:
Years = IF('TableA'[Div] = "AA1", 1, DATEDIFF('TableA'[StarDate], TODAY(), Year))
A I want to get the above value on TableB:
YearsRef = 'TableA'[Years]
But got an error like that:
A single value for column 'xxxxx' in table 'xxxxxx' 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.
Any advice please to solve that?
Thanks in advance,
Vadi
It depends on the relationship between Tables A and B. If Table A is on the 1 side, you can use RELATED('TableA'[Years]). If reversed, you can use RELATEDTABLE() and an aggregation function like MIN() to get to your result. You can also use LOOKUPVALUE(), in many situation or if no relationship at all.
You should also consider doing what you need with measures instead of calculated columns. Much of what is done in columns should be done in measures.
If this works for you, please mark it as solution. Kudos are appreciated too. Please let me know if not.
Regards,
Pat
To learn more about Power BI, follow me on Twitter or subscribe on YouTube.
Hi Pat,
Thank you for your advice.
There is no relationship between two tables and I can make a relationship many to many only.
Years column has values on TableA like the following:
1
1
8
I want to get these same values on TableB.
Thank you,
Vadi
This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.
Check out the June 2025 Power BI update to learn about new features.
User | Count |
---|---|
10 | |
9 | |
8 | |
7 | |
6 |
User | Count |
---|---|
15 | |
13 | |
11 | |
9 | |
8 |