Dec 16, 2022 12:20 AM
Hi. I,m trying to filter records using filter formula based on record_id. The field is not exists in the table, and we don't want to create formula field to have record ids explicitly. Is there a way to compose query formula to filter data by their record_Ids like this:
AND(OR(SEARCH(",recctaxd2aq9fvtfj,", "," & SUBSTITUTE(LOWER(ARRAYJOIN({record_id}) & ","), ", ", ","))))
Thanks in advance.
Solved! Go to Solution.
Dec 16, 2022 04:48 AM
I found the solution, Just instead of {record_id} I used {RECORD_ID()} function in query like this:
AND(OR(SEARCH(",recctaxd2aq9fvtfj,", "," & SUBSTITUTE(LOWER(ARRAYJOIN({RECORD_ID()}) & ","), ", ", ","))))
Dec 16, 2022 01:18 AM
I don’t understand what it is that you’re trying to achieve - could you please provide a couple of mock-up images to help explain?
Dec 16, 2022 02:38 AM
OK. this is my demo table, which has several records. I do not defined recordid field for my records, but as we know each record has record id like this "recctaxd2aq9fvtfj". So in my application I have conditional filters to fetch data from table by Brand, Name, Model etc.... I want to fetch data bu record id as well, but dont want to explicitly define record_id column in my table. I want to use the record id which comes with each record as you can see in code response screenshot.
So this query is working:
AND(OR(SEARCH(",MI 9T pro", "," & SUBSTITUTE(LOWER(ARRAYJOIN({Model}) & ","), ", ", ","))))
But this is not working:
AND(OR(SEARCH(",recctaxd2aq9fvtfj,", "," & SUBSTITUTE(LOWER(ARRAYJOIN({record_id}) & ","), ", ", ","))))
Dec 16, 2022 04:48 AM
I found the solution, Just instead of {record_id} I used {RECORD_ID()} function in query like this:
AND(OR(SEARCH(",recctaxd2aq9fvtfj,", "," & SUBSTITUTE(LOWER(ARRAYJOIN({RECORD_ID()}) & ","), ", ", ","))))