I'm struggling with attempting to write the PA equivalent of a SQL where clause. In this Bold line below I want to flag records to be deleted in TempOptions that have the same QID as a parent record in TempQuestions that has already been marked with the delete flag. PA doesn't like using Filter with =.
Is there a way to filter the multiple records in TempOptions and flag them based on the matching the QID and delete flag from another table (TempQuestions)?
Patch(TempQuestions, LookUp(TempQuestions, QuestionText = ThisItem.Question),{Delete: 1}); ForAll(TempQuestions,Patch(TempOptions, First(Filter(TempOptions, QID = TempQuestions.QID && TempQuestions.Delete = 1)),{Delete: 1})); Remove(TempQuestions,Filter(TempQuestions, Delete > 0)); Remove(TempOptions,Filter(TempOptions, Delete > 0)); Patch(QuestionPool,ThisItem,{Loaded: 0});