Save the date! Join us on October 16 for our Product Ops launch event. Register here.
Oct 09, 2017 10:14 PM
Would anyone tell me how I should go over my trouble with Airtable api?
I would like pick up data from my table by curl with
“filter by formula”
i.e. filterByFormula: ‘(FIND(“0011”,Code))> 0)’,
it is OK with record which has only one data “0011” in “Code” field. (I can get the record)
but
it is NOT GOOD with record which has two or more date (ofcourse one of them is “0011”) in “Code” field.
(the request will not return this record)
it is same for filterByFormula: ‘(SEARCH(“0011”,Code))> 0)’,
Is there any mistake I made to handle this request curl ?
Or would you please tell me how can I fix the formula to get all the records include “0011” ?
//table condtion:
The field “Code” is customized as “Formula” to get date from another field “Code ID”
formula {CodeID}
The field “Code ID” is customized as “Lookup” to get linked date from another field.
Oct 09, 2017 11:46 PM
What happens without the ‘>0’? AFAIK you don’t need it.
If it still doesn’t work you might need to change the formula to flatten the array to plain text. But this is from the top of my head…
Let me know when you still need help. :slightly_smiling_face:
Oct 10, 2017 06:09 AM
Thanks Tuur !
I did now, remove ‘>0’from the formula, but the resulut is same.
it returns records with only “0011” but does not return records with “001100220033”…
(no problem on airtable filtering INCLUDE “0011”…
What do you mean "change the formula to flatten the array to plain text "
Sould I do it on my Airtable ???
Tuur, thanks again, you are great help for me!
Oct 10, 2017 06:44 AM
Strange. If I try the following as URL on one of my tables it works fine…
&filterByFormula=(FIND("Plate",{Product Name}))
The result set returns every record with ‘Plate’ somewhere in the name.
If the array is the problem you can try changing your formula. The following will turn an array into a plain string:
ARRAYJOIN({CodeID})
Good luck!
Oct 10, 2017 04:05 PM
Thanks Tuur, you brought me out from the situation,
Now I tried
ARRAYJOIN({CodeID})
in the field of Airtable and it works well.
Thank you again Turr,
additional question.
is there any tutorial to handle these formula /url (in detail) on WEB?
('cause I could find “FIND” also just in this forum…)
would you plese let me know, if you knowl
Good Day,Tuur !
Oct 10, 2017 11:39 PM
Maybe this helps…
Oct 11, 2017 02:43 AM
Thanks Tuur,
It’lj be a great help !