@RandyHayes @WarrenBelz
Rather than keep beating my head against a wall I am begging for help.
I have a canvas app that has a form that creates a record in one SharePoint list.
I have Gallery1 that is a list of Hazards that creates a collection with this code on the onselect of a button in the gallery :
Select(Parent);
If(
IsBlank(LookUp(colParentGalleryData, Title = ThisItem.Title)),
Collect(
colParentGalleryData,
{
Title: ThisItem.Title,
Examples: ThisItem.Examples,
JSRAction: "Safe", // Placeholder
HazardIssue: "None", // Placeholder
FurtherAction: "None", // Placeholder
CRNumber: "0", // Placeholder
Recognition: "", // Placeholder
OverallComments: "", // Placeholder
Data: Table() // Initialize with an empty table
}
),
RemoveIf(colParentGalleryData, Title = ThisItem.Title)
);
this is where the frustration starts. I have a parent/child nested gallery that is tied to the collection referenced above.
This is on the ParentGallery
SortByColumns(
GroupBy(
colParentGalleryData,
"Title",
"Examples",
"Data"
),
"Title",
SortOrder.Ascending
)
And this is on the ChildGallery
ThisItem.Data
When the form and all of the gallery information is completed I have two things that should be happening.

The submit button on the screen has this:
Patch(
'Job Site Review(Testing)',
LookUp('Job Site Review(Testing)', ID = CurrentFormID),
{
SafetyMeetingGroup: DataCardValue1.Selected.Title,
'Location Choice': DataCardValue4.Selected.Value,
'Location of Observation': DataCardValue7.Selected.ChildLocation
}
);
and on the OnSuccess of the form I have this
ClearCollect(colChildItems, ChildGallery.AllItems);
// Loop through each parent record
ForAll(
ParentGallery.AllItems,
Patch(
'Job Site Review(Testing)',
Defaults('Job Site Review(Testing)'),
{
'Reviewer 1': {
'@odata.type': "#Microsoft.Azure.Connectors.SharePoint.SPListExpandedUser",
Claims: "i:0#.f|membership|" & DataCardValue2.Selected.Email,
DisplayName: DataCardValue2.Selected.DisplayName,
Email: DataCardValue2.Selected.Email,
Id: "",
JobTitle: "",
Department: "",
Picture: ""
},
'Review Date': DataCardValue59.SelectedDate
}
).ID
);
// Nested loop to patch each child record for the current parent
ForAll(
colChildItems,
Patch(
JobSiteReviewHazards,
Defaults(JobSiteReviewHazards),
{
MasterID: CurrentFormID,
JSRAction: JSRAction,
HazardIssue: HazardIssue,
FurtherAction: FurtherAction,
CRNumber: Value(CRNumber),
Recognition: "",
OverallComments: ""
}
)
)
What is happening is the first patch is working just fine but nothing is patching with the second for the ChildItems. I am stumped and I have been looking for days for this solution.
Any help would so be apprecaited.