Filtering Data

Created by Roanne Jane Jane Jaype, Modified on Mon, 1 Aug, 2022 at 3:35 PM by Roanne Jane Jane Jaype

Data can be filtered using exact values and wildcard matching ( * ).

Filtering by Column

Column filtering can be done in a simple way by appending /<Column Name>/<Column Value> suffix into the URL.

You can filter all rows with Jane Doe exact value inside Name column by appending the suffix /Name/Jane Doe.

You can use wildcard matching by using the * character inside the suffix.

  • You can filter all rows with Jane inside the Name column by appending the suffix /Name/*Jane*.
  • You can filter all rows that starts with Jane inside the Name column by appending the suffix /Name/Jane*.
  • You can filter all rows that ends with Jane inside the Name column by appending the suffix /Name/*Jane.

Filtering multiple columns

You can filter multiple columns by using the /search suffix, combined with the query params following the pattern <Column Name>=<Column Value>.

Wildcard matching works when filtering multiple columns too.

  • You can filter all rows with Jane inside the Name column and 21 in the Age column by appending the suffix: /search?Name=*Jane*&Age=21

Combining Filters with Tabs

You can filter other tabs data by appending /tabs/<Tab Name> before the filter suffixes:

  • You can filter all rows with Mick inside the Name column and 21 in the Age column with using the suffix: /tabs/Admin/search?Age=21&Name=*Mick*


___________________


  Shell

# Only rows with "Jane Doe" as "Name"
curl 'https://sheet.best/api/sheets/cf969697-682a-40e3-bad4-d54803eeeacf/Name/Jane Doe'

# Only rows with "John" inside "Name"
curl 'https://sheet.best/api/sheets/cf969697-682a-40e3-bad4-d54803eeeacf/Name/*John*'

# Only rows with "John" inside "Name" and with "Age" as "56"
curl 'https://sheet.best/api/sheets/cf969697-682a-40e3-bad4-d54803eeeacf/search?Name=*John*&Age=56'

# Only rows with "Arthur" inside "Name" inside "Admin" tab
curl 'https://sheet.best/api/sheets/cf969697-682a-40e3-bad4-d54803eeeacf/tabs/Admin/Name/*Arthur*'
HTML

  Python

import requests

# Only rows with "Jane Doe" as "Name"
requests.get('https://sheet.best/api/sheets/cf969697-682a-40e3-bad4-d54803eeeacf/Name/Jane Doe')

# Only rows with "John" inside "Name"
requests.get('https://sheet.best/api/sheets/cf969697-682a-40e3-bad4-d54803eeeacf/Name/*John*')

# Only rows with "John" inside "Name" and with "Age" as "56"
requests.get('https://sheet.best/api/sheets/cf969697-682a-40e3-bad4-d54803eeeacf/search?Name=*John*&Age=56')

# Only rows with "Arthur" inside "Name" inside "Admin" tab
requests.get('https://sheet.best/api/sheets/cf969697-682a-40e3-bad4-d54803eeeacf/tabs/Admin/Name/*Arthur*')
HTML

  Javascript

// Only rows with "Jane Doe" as "Name"
fetch(
  "https://sheet.best/api/sheets/cf969697-682a-40e3-bad4-d54803eeeacf/Name/Jane Doe"
);

// Only rows with "John" inside "Name"
fetch(
  "https://sheet.best/api/sheets/cf969697-682a-40e3-bad4-d54803eeeacf/Name/*John*"
);

// Only rows with "John" inside "Name" and with "Age" as "56"
fetch(
  "https://sheet.best/api/sheets/cf969697-682a-40e3-bad4-d54803eeeacf/search?Name=*John*&Age=56"
);

// Only rows with "Arthur" inside "Name" inside "Admin" tab
fetch(
  "https://sheet.best/api/sheets/cf969697-682a-40e3-bad4-d54803eeeacf/tabs/Admin/Name/*Arthur*"
);
HTML


Was this article helpful?

That’s Great!

Thank you for your feedback

Sorry! We couldn't be helpful

Thank you for your feedback

Let us know how can we improve this article!

Select at least one of the reasons
CAPTCHA verification is required.

Feedback sent

We appreciate your effort and will try to fix the article