Hello, I have a list coming from SharePoint where there are more than 2K records. Two collections were created for first 2K, and then for remaining and then a combined collection. I am usning the combined collection as part of the items in gallery, but running into an issue where the IDs are repeating in the gallery. Any ideas on below?
OnVisible – Screen:
ClearCollect(TempCollection,'eCom Intake'); //Create a temporary collection for the first 2,000 items
ClearCollect(RemainingItems, Filter('eCom Intake',ID > First(TempCollection).ID)); //Create another collection to store the remaining items (>2,000)
ClearCollect(CombinedCollection, TempCollection, RemainingItems) //Combine the two collections to get the desired range of items
Items Property in Gallery:
With(
{
_prefiltered_data: Filter(
CombinedCollection,
Status.Value = "Resolved",
Len(Dropdown4_2.Selected.Value) = 0 || LOB.Value = Dropdown4_2.Selected.Value,
Len(Dropdown4_3.Selected.Value) = 0 || 'Issue Type'.Value = Dropdown4_3.Selected.Value,
!Checkbox1_1.Value || 'Created By'.Email=User().Email
)
},
With(
{
_transformed_data: AddColumns(
_prefiltered_data,
TextID,
Text(ID),
CreatedByDisplayName,
'Created By'.DisplayName,
AssignedToDisplayName,
AssignedTo.DisplayName,
ChoiceString,
'NeedMoreInfoOPS - Current'.Value
)
},
With(
{
_filtered_by_names: Search(
_transformed_data,
SearchInput_tb_1.Text,
Title,
CreatedByDisplayName,
AssignedToDisplayName
),
_filtered_by_id: Search(
_transformed_data,
SearchInput_tb_1.Text,
TextID
)
},
With(
{
_finaltable: If(
!SearchID_tg_1.Checked && !SearchRequestor_tg_1.Checked,
_filtered_by_names,
_filtered_by_id
)
},
SortByColumns(
_finaltable,
"ChoiceString",
SortOrder.Descending,
"ID",
SortOrder.Ascending
)
)
)
)
)