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

Calling all Data Engineers! Fabric Data Engineer (Exam DP-700) live sessions are back! Starting October 16th. Sign up.

Reply
Shifty1993
Regular Visitor

Is it possible? Creating a relationship between a measure and a cell of a column (of a table)

Hello community,

 

Is there any way to set up a relationship between a measure and a Column of a table?

 

So what I thought is the following:

1) I created a new table with the GENERATESERIES() Function. In this function I just put in a span of integers (For example 1 until 10)

2) I created 10 measures for every integer value.

3) Usually I just can create relationships between tables. But now I would like to have a 2-Tuple.

4) I considered to do something like this / the idea: { (1, measure_result_1), (2, measure_result_2), ..., (10, measure_result_10) }

5) Result should be a visualisation with 1 until 10 on x-axis and the corresponding results on the y-axis.

 

Thanks in advance

1 ACCEPTED SOLUTION
Jihwan_Kim
Super User
Super User

Hi,

Please check the below picture and the attached pbix file.

I tried to create a sample pbix file like below, and I hope the below can provide some ideas on how to create a solution for your dataset.

 

Jihwan_Kim_0-1662639410790.png

 

 

Expected result measure: =
SWITCH (
    TRUE (),
    SELECTEDVALUE ( 'Axis table'[Value] ) = 1, CALCULATE ( SUM ( Data[Quantity] ), Data[Category] = "Ca01" ),
    SELECTEDVALUE ( 'Axis table'[Value] ) = 2, CALCULATE ( SUM ( Data[Quantity] ), Data[Category] = "Ca03" ),
    SELECTEDVALUE ( 'Axis table'[Value] ) = 3, CALCULATE ( SUM ( Data[Quantity] ), Data[Category] = "Ca08" )
)

If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Click here to visit my LinkedIn page

Click here to schedule a short Teams meeting to discuss your question.

View solution in original post

2 REPLIES 2
Jihwan_Kim
Super User
Super User

Hi,

Please check the below picture and the attached pbix file.

I tried to create a sample pbix file like below, and I hope the below can provide some ideas on how to create a solution for your dataset.

 

Jihwan_Kim_0-1662639410790.png

 

 

Expected result measure: =
SWITCH (
    TRUE (),
    SELECTEDVALUE ( 'Axis table'[Value] ) = 1, CALCULATE ( SUM ( Data[Quantity] ), Data[Category] = "Ca01" ),
    SELECTEDVALUE ( 'Axis table'[Value] ) = 2, CALCULATE ( SUM ( Data[Quantity] ), Data[Category] = "Ca03" ),
    SELECTEDVALUE ( 'Axis table'[Value] ) = 3, CALCULATE ( SUM ( Data[Quantity] ), Data[Category] = "Ca08" )
)

If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Click here to visit my LinkedIn page

Click here to schedule a short Teams meeting to discuss your question.
Greg_Deckler
Community Champion
Community Champion

@Shifty1993 Maybe:

Measure =
  SWITCH('Table'[Index],
    1, [measure1],
    2, [measure2],
    3, [measure3],
    4, [measure4],
    ...
  )


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
DAX For Humans

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
FabCon Global Hackathon Carousel

FabCon Global Hackathon

Join the Fabric FabCon Global Hackathon—running virtually through Nov 3. Open to all skill levels. $10,000 in prizes!

September Power BI Update Carousel

Power BI Monthly Update - September 2025

Check out the September 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.