cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Robertjde
Helper V
Helper V

Ideas for creating a ranking

I have an incident report application.
The data or the entries all go to an SP list.

 

I would now like to build a ranking in the application from my SP list and have no idea how I can implement it.

 

What i need is:

- What was the most common reason (column AN)

-What was the most common cause (column ART)

 

Here is an example gallery with the contents of my SP List

 

Report_Ranking.PNG

1 ACCEPTED SOLUTION

Accepted Solutions

Hi @Robertjde ,

So do you mean the sort order is:

1. Flow Wrap - Visual Standard nok;

2. T-Disc - Siegelung nok ;

3. other fields?

 

Since you need the value of two fields, so I suggest you use addcolumn functions to add a column, then sort based on this new column.

Try to set the gallery's Items like this:

Sort(
      AddColumns(
                  Filter('QA vOR...',Datum>=Datepicker2.SelectedDate&&Datum<=Datepicker1.SelectedDate),
                  "sortorder",
                  If(ANfieldname="Flow Wrap"&&ARTfieldname="Visual Standard nok",3,
                     ANfieldname=" T-Disc"&&ARTfieldname="Siegelung nok",2)
                 ),
        sortorder,Descending)

 

//please fill in your list name and fieldname

 

Best regards,

Community Support Team _ Phoebe Liu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

3 REPLIES 3
v-yutliu-msft
Community Support
Community Support

Hi @Robertjde ,

Could you describe more clearly about the "ranking" in your app?

Whether do you want to add a column to record the ranking 

                                         or sort based on column AN and column ART?
I assume that you want to sort based on column AN and column ART.

If so, could you tell me your sort  order?

If you want to SortOrder  is SortOrder.Descending or SortOrder.Ascending, things will be easy.

You just need to set the gallery's Items like this:

SortByColumns(tablename,"AN",SortOrder.Ascending,"ART",SortOrder.Descending)

 

 

Best regards,

Community Support Team _ Phoebe Liu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

@v-yutliu-msft 

 

Exactly, I want to sort based on column AN and column ART.

Before that I use a filter by date.

 

unfortunately your proposed solution does not work 100%

 

in this example it should be sorted in the following order ...

All points with....

1. Flow Wrap - Visual Standard nok

2. T-Disc - Siegelung nok 

 

SortOrder.JPG

Hi @Robertjde ,

So do you mean the sort order is:

1. Flow Wrap - Visual Standard nok;

2. T-Disc - Siegelung nok ;

3. other fields?

 

Since you need the value of two fields, so I suggest you use addcolumn functions to add a column, then sort based on this new column.

Try to set the gallery's Items like this:

Sort(
      AddColumns(
                  Filter('QA vOR...',Datum>=Datepicker2.SelectedDate&&Datum<=Datepicker1.SelectedDate),
                  "sortorder",
                  If(ANfieldname="Flow Wrap"&&ARTfieldname="Visual Standard nok",3,
                     ANfieldname=" T-Disc"&&ARTfieldname="Siegelung nok",2)
                 ),
        sortorder,Descending)

 

//please fill in your list name and fieldname

 

Best regards,

Community Support Team _ Phoebe Liu
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

View solution in original post

Helpful resources

Announcements
PA_User Group Leader_768x460.jpg

Manage your user group events

Check out the News & Announcements to learn more.

Power Query PA Forum 768x460.png

Check it out!

Did you know that you can visit the Power Query Forum in Power BI and now Power Apps

Carousel 2021 Release Wave 2 Plan 768x460.jpg

2021 Release Wave 2 Plan

Power Platform release plan for the 2021 release wave 2 describes all new features releasing from October 2021 through March 2022.

PowerPlatform 768x460.png

Microsoft Learn

Check out our new Discover Your Career Path blog post series and get all the details.

Users online (1,674)