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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Anonymous
Not applicable

Relationships between tables

Hi everyone,

Please help me with the solution as I am a beginner in Power BI.

I am getting data from an online SharePoint List. Where Incident is Main List and Person and Witness are sub-lists.

So every incident can have N number of Persons (or/and )N number of Witnesses. I tried creating a relationship as below

Incident ID (Incident ) --1 to many --> Incident ID (Person )
Incident ID (Incident ) --1 to many --> Incident ID (Witness)
But when creating a table while adding all the columns from 3 tables I get the below error.

Ashfiya_Naaz_1-1666032654368.png

 

 

1. Incident Table ( The main table where Incident ID is always unique )

Incident_ID 

Incident_Name

Status

1

Fire

In Progress

2

Blowdown Valve

Completed

3

Alarm

Canceled

 

2. Person Table

ID

Incident_ID

Person_Name

Person_Staff_ID

1

1

Jack

222

2

1

Mack

223

3

1

Amy

224

4

3

Jack

222

 

3. Witness Table

Incident_ID

Witness_Name

Witness_Staff _ID

2

Joan

11

2

Joseph

12

1

Alex

13

 

I tried creating a relationship as shown below

Ashfiya_Naaz_0-1666032279041.png

But what happens in the table is the Witness Details get Repeated 3 times since the Person Details has 3 records.

Incident_ID

Incident_Name

Status

Person_Name

Person_Staff_ID

Witness_Name

Witness_Staff_ID

1

Fire

In Progress

Jack

222

Alex

13

1

Fire

In Progress

Mack

223

Alex

13

1

Fire

In Progress

Amy

224

Alex

13

 

I want a summary table where it contains all the records from all 3 tables or a matrix where when expanding we get something like this or blank values for (Witness/ Person)  if details are not present. 

Incident_ID

Incident_Name

Status

Person_Name

Person_Staff_ID

Witness_Name

Witness_Staff_ID

1

Fire

In Progress

Jack

222

Alex

13

 

 

 

Mack

223

 

 

 

 

 

Amy

224

 

 

 

 

Regards,
Ashfiya

2 REPLIES 2
Shaurya
Memorable Member
Memorable Member

Hi @Anonymous,

 

Your relationships should be:

 

  1. Incident ID -- * to 1 -- Person
  2. Incident ID -- * to 1 -- Witness

 

Make sure that both the relationships have a single directional cross filter.

 

Did I answer your question? Mark this post as a solution if I did!
Consider taking a look at my blog: Forecast Period - Previous Forecasts

Anonymous
Not applicable

Hi @Shaurya ,

Thanks for the reply,  can you please elaborate more on Incident ID of which table,? as mentioned earlier the Incident ID ( Incident table is unique )

  1. Incident ID (incident) -- * to 1 -- Person
  2. Incident ID (incident) -- * to 1 -- Witness

This cardinality is invalid.

 

1. Incident ID (Incident ) --1 to many --> Incident ID (Person )
2. Incident ID (Incident ) --1 to many --> Incident ID (Witness)
But when creating a table while adding all the columns from 3 tables I get the below error.

Ashfiya_Naaz_0-1666064605024.png

 

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

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.