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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Learn more

Reply
Anonymous
Not applicable

Getting a List of Values from a Measure Aggregate

Hi,

 

I don't know if this is possible, but I would like to return a list of values from an aggregated measure.

 

I have a measure called 'Start' that returns 1 or 0 based on some conditions. I use this measure in another measure to calculate the number of contracts that meet this criterion:

 

 

 

Number Start = CALCULATE(DISTINCTCOUNT(Retention[contract_id]), FILTER(Retention, [Start] = 1))

 

 

 

The reason I have this as a measure and not a calculated column, is that the 'Start' measure is based off values in a slicer, so it needs to be dynamic.

 

I would like to be able to get all the values as a list that make up the DISTINCTCOUNT in the above measure.

 

The closest I've been able to get is this:

 

 

 

Measure = 
CALCULATE(CONCATENATEX (
    VALUES ( Retention[contract_id] ),
    Retention[contract_id],
    UNICHAR ( 10 ),
    Retention[contract_id]
), FILTER(Retention, [Start] = 1))

 

 

 

But this is all one string, whereas I would like each contract ID on a separate line.

 

Does anyone know if this is actually possible?

Any help would be much appreciated.

 

3 REPLIES 3
Ashish_Mathur
Super User
Super User

Hi,

As a sidenote, your measure can be simplified to:

 

Number Start = CALCULATE(DISTINCTCOUNT(Retention[contract_id]),Retention[Start] = 1)

 


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
DataInsights
Super User
Super User

@Anonymous,

 

Try replacing the CONCATENATEX portion of your measure with this. The delimiter is an empty string.

 

CONCATENATEX ( Retention, Retention[contract_id] & UNICHAR ( 10 ), "" )

 

DataInsights_0-1645020986610.png

 

 





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

Proud to be a Super User!




The delimiter is optional, so you can simplify:

 

CONCATENATEX ( Retention, Retention[contract_id] & UNICHAR ( 10 ) )




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

Proud to be a Super User!




Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

Check out the October 2025 Power BI update to learn about new features.

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors