This is a simple example template to show how you can change query parameters of a PocketQuery macro dynamically with a dropdown.
Prerequisites: you have a PocketQuery macro with the Load macro dynamically checkbox checked.
Again, we are using sample WorldDB for illustration purposes. I'm querying the population numbers of different countries by the country's continent, where Continent is my only query parameters. This is what the result looks like:
This is the simplest template for achieving a dynamic dropdown. The PocketQuery macro must be added to a page with the Load macro dynamically and Enable dynamic parameters options checked. More advanced scenarios could, for example, populate the select options for a separate SQL query. If you have a specific scenario you can raise an issue in our support Jira.
But back to the simple example. My query is a fairly simple SQL statement and looks like this (it works the same way for REST API queries):
SELECT Name, Population FROM Country WHERE Continent = :Continent
I admit that this template looks a bit bloated. But it's also because of the many comments. And after all PocketQuery templates will always need programming if the standard is not sufficient.