Hello,
I have a inputtextfield where I search for ordernumbers in sp list. I have a gallery which is based on that list (tblOrders) and it displays all those records according to that filter:
Filter(tblOrders; Ordernumber = TextInput1_1.Text)
Ordernumbers are not necessarily distinct. For one ordernumber I might get several records. I add another label with:
I have a true false check column (columnB). Whenever I got a records, where in Column A is no string of "PDF" than I get false.
When there is at least one false in the result, I want the whole gallery result to be patch into a collection called "colOrdernumber.
I used following.
Collect(colOrdernumbers;Gallery.AllItems)
But seemingly the formular only works on the first row of a gallery, not on all rows. How to get all records of a result which has a least one "false" in columnB.
Thank you very much in advance.
Best.
Solved! Go to Solution.
Hi @Applicable88 ,
I made a sample for you.
Filter(LIST301,Ordernumber=TextInput1.Text)
If(CountRows(Filter(AddColumns(Filter(LIST301,Ordernumber=TextInput1.Text),"temp",If(ThisRecord.Title="PDF", true , false )),temp= false ))>0,Collect(Col,Filter(LIST301,Ordernumber=TextInput1.Text)))
Best Regards,
Wearsky
Hi @Applicable88 ,
I made a sample for you.
Filter(LIST301,Ordernumber=TextInput1.Text)
If(CountRows(Filter(AddColumns(Filter(LIST301,Ordernumber=TextInput1.Text),"temp",If(ThisRecord.Title="PDF", true , false )),temp= false ))>0,Collect(Col,Filter(LIST301,Ordernumber=TextInput1.Text)))
Best Regards,
Wearsky
@v-xiaochen-msft thank you very much! That should work for me. I wonder why all my approaches with patch and filter didn't work before, but here you doing a temprorary "addcolumns" and also a "countrows" of the ones which are false. Why is that needed?
And why that simple formular doesn't work with thisRecord or allItems? :
Collect(colOrdernumbers;Gallery.AllItems)
Best.
User | Count |
---|---|
121 | |
88 | |
88 | |
75 | |
66 |
User | Count |
---|---|
217 | |
180 | |
138 | |
96 | |
73 |