openoffice-base

Is it possible to create a parameter query in openoffice base?


In access it is very easy to use it: BETWEEN [minimum] AND [maximum]

But what is the syntax in openoffice base?


Solution

  • There are two ways to do this. First is to have the query ask for user input. Colons are used to indicate user-input parameters, like this:

    BETWEEN :MINIMUM AND :MAXIMUM
    

    Second is to use a one-row filter table. Tie the user's form to this one row by making the form source something like SELECT * FROM "Filter" WHERE "FilterID" = 1. Then the user will enter the dates into the filter table, and the query will have a join to the filter table to determine the dates.