Oct 28, 2022 06:16 PM
So if I do a formula like this in AirTable:
phone=‘+61 432 777 028’
it can figure out the + and even the space - but it gets more complicated when trying to filter by formula through API… now I’m sure i’m missing something but here is the proof… in video form!
Tldr: spaces are not working in AirTable filter formula through API
Minor issue but just thought I’d point it out
Oct 28, 2022 07:46 PM
What happens if you encode your spaces as
%20 instead of
Oct 28, 2022 07:52 PM
On my end, spaces work just fine for me, regardless of whether they are %20 or +.
So it seems like something else is going on.
I would try it in Postman to see if you get any different results.
Oct 28, 2022 08:12 PM
Also, you’re telling Airtable to only show you the value for the field “First”. Are you sure you have something in that field for the latest record that you’re testing?
You may also want to remove the field parameter altogether to see what happens.
Oct 28, 2022 11:58 PM
Heyy!! Great idea. I should have tried that…
Oct 29, 2022 12:00 AM
hey, on the first example you can see the First named field shows up - it’s only when I add the space… but I can try %20 I should have tried that first… it’s interesting + works for you along with %20… that’s why I added a video lol… I appreciate the quick responses! In either case I removed spaces manually so I wouldn’t have to search for spaces and it wouldn’t be required - just thought it was interesting to point out… curious is all
Oct 29, 2022 12:54 AM
“First” is not shown in your video.
Also, you are choosing 2 completely different records in your video.You didn’t just change one record to spaces vs. no spaces, which would have been the correct test to perform.
What you did is that you chose a completely different record that might not have anything for “First”. Like I mentioned above, if your 2nd record doesn’t have a value for “First”, then you’re going to get an empty response from the API because you told it to only show you “First”. So, like I mentioned above, I would remove that part from your API call and see if it works.
If that still doesn’t work after that, then like I mentioned above, I would try it in Postman and see what happens.
I would also try using double quotes instead of single quotes to see if that makes a difference.
Oct 29, 2022 02:00 AM
Hey thank, really? I didn’t do a completely parallel test in comparison? If that’s the case I apologise… in either case I’ve got the functionality working that this relied on and AirTable api is working fine (I just removed all the spaces so this issue no longer was relevant)