Hi all,
I have a slow performance on an app even thou my list is quite small. Let me explain the full scenario:
I have a list with companies and a list with clusters. The same number of clusters apply to all companies, meaning an analyst is not assigned the entire company , but one cluster.
When they open the app I have a screen with two galleries:
1. With the cluster list
2. With the companies list
Because they don't assign themselves to the entire company I have another list called "Cluster Research". The second gallery has a AddColumns so that it only shows companies that DO NOT have research generated. For this reason, even if I have 500 companies in the list, the app is very slow at this step.
This is the code for the second gallery:
If(IsBlank(selectedcluster),Blank(),SortByColumns(Filter(AddColumns(Filter(Companies,CompanysCycle=researchcycle),"Should be visible?",If(IsEmpty(Filter(ClusterResearch,ClusterResearchCycleID=researchcycle,CompanyIDClusterResearch=CompanyID,ClusterID=selectedcluster.ClusterID)) Or LookUp(ClusterResearch,ClusterResearchCycleID=researchcycle And CompanyIDClusterResearch=CompanyID And ClusterID=selectedcluster.ClusterID And AnalystEmailperCluster=currentuseremail,ClusterStatus)="In progress","Yes","No"),"Own company?",If(LookUp(ClusterResearch,ClusterResearchCycleID=researchcycle And CompanyIDClusterResearch=CompanyID And ClusterID=selectedcluster.ClusterID).AnalystEmailperCluster=currentuseremail,"Yes","No")),'Should be visible?'="Yes"),"Own company?",["Yes","No"]))
Both clusters and companies have research cycles (since the process needs to happen once a year.
Using bigger lists of companies is not working at all, huge delay upon selecting a cluster when the companies need to load.
Thank you in advance!