cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
DennisJumped
Frequent Visitor

Building a decision tree in Powerapps

Hello,

 

I am very new to powerapps. I have been trying to make a decision tree based on a sharepoint online list. The idea is that people are able to add items to the list so extra option become available in the application. It will be a troubleshooting application that determines the issue, possible cause, and then a solution. The idea is that people are able to add items to the sharepoint list so extra options become available in the application. The list looks something like this:

 

Head Cat.Head Cat. Desc.Sub Cat.Sub Cat. Desc. SolutionPictures
Head Cat. AHead Cat. Desc. ASub. Cat. ASub. Cat. Desc. ASolution Apic1,pic2,pic3
Head Cat. AHead Cat. Desc. ASub. Cat. BSub. Cat. Desc. BSolution Bpic1,pic2,pic3
Head Cat. BHead Cat. Desc. BSub. Cat. ASub. Cat. Desc. ASolution Apic1,pic2,pic3
Head Cat. BHead Cat. Desc. BSub. Cat. CSub. Cat. Desc. CSolution Cpic1,pic2,pic3

 

There are few steps in the decision tree:

1. Main categories

2. Subcategories

3. Possible causes

4. Solutions

 

It looks a little bit like this.

 

Formulatie - Dennis - Frame 1 (1).jpg

 

 

 

 

 

 

 

 

I am using a gallery to show the main categories. However, I only want to show the distinct values. I have managed to only show the distinct values by using distinct or group by, however, I am not able to show the main category description or the pictures. 

Screen 1 shows the main categories with:

- Picture 1

- ThisItem.Head Cat.

- ThisItem. Head Cat. Desc. 

 

Is there a way to filter for the distinct values and still show the corresponding data? Any other advice is welcome as well. 

 

Regards,

Dennis

 

1 ACCEPTED SOLUTION

Accepted Solutions
Drrickryp
Super User
Super User

Hi @DennisJumped 

This is a design issue.  You should examine your table to find One to Many relationships and separate them out as separate lists.  You then link them using the ID column of a One side in the Many side of the table.  For the rationale and how to do this in PowerApps please see my blog post here https://powerusers.microsoft.com/t5/News-Announcements/Relational-Database-Principles-and-PowerApps-...  

View solution in original post

1 REPLY 1
Drrickryp
Super User
Super User

Hi @DennisJumped 

This is a design issue.  You should examine your table to find One to Many relationships and separate them out as separate lists.  You then link them using the ID column of a One side in the Many side of the table.  For the rationale and how to do this in PowerApps please see my blog post here https://powerusers.microsoft.com/t5/News-Announcements/Relational-Database-Principles-and-PowerApps-...  

Helpful resources

Announcements
Power Apps News & Annoucements carousel

Power Apps News & Announcements

Keep up to date with current events and community announcements in the Power Apps community.

Community Call Conversations

Introducing the Community Calls Conversations

A great place where you can stay up to date with community calls and interact with the speakers.

Power Apps Community Blog Carousel

Power Apps Community Blog

Check out the latest Community Blog from the community!

Top Solution Authors
Top Kudoed Authors
Users online (6,274)