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

Delegation problem

I was using a excel sheet as my bd, yesterday i change my bd to an sharepoint list, but when i migrate to sharepoint, some delegation problems started to pop out, as you can see in my screen shots. 

 

If(IsBlank(TextSearchBox2_2.Text);
   SortByColumns(
      Filter (BD_Coletor_1;
          Usuario <> "-"
);
   "Usuario";Ascending
);
If ( TextSearchBox2_2.Text = "Divergente"; 
   SortByColumns(
      Filter (
           BD_Coletor_1;
           Status= "Divergente"
              );"Status"; Ascending);
Search(
        BD_Coletor_1;
        TextSearchBox2_2.Text;
        "Usuario"
      )
                 )
)

 

 Everything seems to be working fine, but this delegation problem keeps making me felling anoyed. 
There is 3 Delegation problems with my gallery:
   - With my Filter
   - With my Search
   - And one linked to my user column, that i just dont understando. 

Overview: Audit app, to help my area to keeps control of wich person is using what asset.
There is probably 40 rows at max. 

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Super User III
Super User III

Re: Delegation problem

@VieiraGuilhermo 
If you have only 40 rows you do not need to care about delegation warnings.  They only affect your app after you have more than 2,000 rows inside a table.

If you will have more than 2,000 rows in your app here's my proposed solution

 

If(
    IsBlank(TextSearchBox2_2.Text);
    Sort(
        Filter (
            BD_Coletor_1;
            StartsWith(Usarsio, "-")
        );
        Usuario; Ascending
    );
    If(TextSearchBox2_2.Text = "Divergente"; 
    Sort(
        Filter(
            BD_Coletor_1;
            Status = "Divergente"
        ); 
        Status; Ascending
    );
    Filter(
        BD_Coletor_1;
        StartsWith(Usuario, TextSearchBox2_2.Text)
    )
)

 

 

An explanation of my changes:

 

#1 SORTBYCOLUMNS:  change all of these to SORT instead.  SORT can be delegated.

#2 SEARCH: replace this with STARTSWITH.  STARTSWITH can be delegated.
#3 Usario <> "-": replace this with STARTSWITH.  The <> operator cannot be delegated.

 

---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

View solution in original post

1 REPLY 1
Highlighted
Super User III
Super User III

Re: Delegation problem

@VieiraGuilhermo 
If you have only 40 rows you do not need to care about delegation warnings.  They only affect your app after you have more than 2,000 rows inside a table.

If you will have more than 2,000 rows in your app here's my proposed solution

 

If(
    IsBlank(TextSearchBox2_2.Text);
    Sort(
        Filter (
            BD_Coletor_1;
            StartsWith(Usarsio, "-")
        );
        Usuario; Ascending
    );
    If(TextSearchBox2_2.Text = "Divergente"; 
    Sort(
        Filter(
            BD_Coletor_1;
            Status = "Divergente"
        ); 
        Status; Ascending
    );
    Filter(
        BD_Coletor_1;
        StartsWith(Usuario, TextSearchBox2_2.Text)
    )
)

 

 

An explanation of my changes:

 

#1 SORTBYCOLUMNS:  change all of these to SORT instead.  SORT can be delegated.

#2 SEARCH: replace this with STARTSWITH.  STARTSWITH can be delegated.
#3 Usario <> "-": replace this with STARTSWITH.  The <> operator cannot be delegated.

 

---
Please click "Accept as Solution" if my post answered your question so that others may find it more quickly. If you found this post helpful consider giving it a "Thumbs Up."

View solution in original post

Helpful resources

Announcements
Community Conference

Power Platform Community Conference

Check out the on demand sessions that are available now!

Power Platform ISV Studio

Power Platform ISV Studio

ISV Studio is designed to become the go-to Power Platform destination for ISV’s to monitor & manage published applications.

secondImage

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Tech Marathon

Maratón de Soluciones de Negocio Microsoft

Una semana de contenido con +100 sesiones educativas, consultorios, +10 workshops Premium, Hackaton, EXPO, Networking Hall y mucho más!

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