How to add rules/conditions to adding table?

So, say there is a form for reservation. You can reserve on any date after today. You can also see current reservations. But, if you enter a date that is already reserved, you shouldn’t be able to add to the table. How do you do that? Now, it just adds it to the table. Thanks

You would need to use a custom form for that.

If it’s just a date and not including the time, you can:

  • Convert the chosen date to numerical value (say have a math column to convert it to MMDDYYYY).

  • Do the same process in the table where you store existing reservations.

  • Create a relation from the chosen date’s numerical value to the existing reservation dates’ numerical values.

  • If the relation is not empty, then don’t allow them to add a row.

The process is much trickier when you add the time in, with periods of time.

2 Likes

This topic was automatically closed 24 hours after the last reply. New replies are no longer allowed.