Query rows via API

I think you would have to create a custom form for that.

  • Create an If-Then-Else column in your User Profiles table called “Parental leave days”. If “children under 12” is over X, then 12 days, else 10 days, structure your logic around this part.
  • Back to your custom form’s helper table, you should have user-specific columns to hold the user’s type of leave request.
  • Create a query column targetting the parental leave records table, filter by the user’s ID/email, and the type of request being the same as the one in your form.
  • Have a submit button in your form. Have a custom action with as many branches of logic as you need. One should be “If query column is empty”, then add a parental leave record, before adding a leave request. Else just add the leave request.
1 Like