Help

Re: Search a column for a specific value using the API

Solved
Jump to Solution
545 0
cancel
Showing results for 
Search instead for 
Did you mean: 
SynopsisLabs
5 - Automation Enthusiast
5 - Automation Enthusiast

Hi,

I am new to Airtable coming from Xano and using Thunkable as my mobile front end.

In Xano I can create and API endpoint which will allow me to search for a specific value in a column in a table.  I see that I use the AirTable API to get a record but that is by record id.

If I wanted to search by a field, email address for example, how would I accomplish this?

Thanks

Steve

1 Solution

Accepted Solutions
rk4bir
4 - Data Explorer
4 - Data Explorer

 

You can search the list using fields. Let's say I have a table that contains columns `source,` `name,` etc. Now, I want to get a list using a query that matches the `source` field/column and returns the field name and source

Here's how to do it:

My Formula: IF(LOWER(source) = LOWER("query"), 1, 0)

Encoded URL (Use this tool to transform your request to an encoded URL):

https://api.airtable.com/v0/<base>/<table>?fields%5B%5D=source&fields%5B%5D=name&filterByFormula=IF(LOWER(source)+%3D+LOWER(%22query%22)%2C+1%2C+0)

 

Send a GET request, and it'll return the search result. I hope it helps!

 

See Solution in Thread

2 Replies 2
rk4bir
4 - Data Explorer
4 - Data Explorer

 

You can search the list using fields. Let's say I have a table that contains columns `source,` `name,` etc. Now, I want to get a list using a query that matches the `source` field/column and returns the field name and source

Here's how to do it:

My Formula: IF(LOWER(source) = LOWER("query"), 1, 0)

Encoded URL (Use this tool to transform your request to an encoded URL):

https://api.airtable.com/v0/<base>/<table>?fields%5B%5D=source&fields%5B%5D=name&filterByFormula=IF(LOWER(source)+%3D+LOWER(%22query%22)%2C+1%2C+0)

 

Send a GET request, and it'll return the search result. I hope it helps!

 

Thanks for the information Will give it a shot!