Find Entries with Matching Date(s)


I have built a reservation app for users to book a desk at the co-working space.
I managed to store booking as a list with 2 fields: desk & date, looking like this:

Let’s say a only 2 desks are available per day for booking.
How do I make a backend workflow to check if there are already 2 entries with the same date, and add that date to an “unavailable date” list (random date & automatically, without manually selecting a date to check)?


On the workflow add a parameter (data that you send when you call the workflow) called date of type date. When you call the workflow pass your desired date through.

Then on the workflow or on the action within the workflow add an only when condition: Do a search for bookings where date = whatever date you want to check and then add :count > 0. This returns true if there are any bookings on that date. Then you can have an action that “Make changes to a thing” and select your list of “Unavailable dates” and add the date in question into that list.