-[[PARAM]]

Substitute arguments for parameters in queries.

Syntax

-[[PARAM]]=ARG
-[[]]@FILE

Description

You can substitute one or more arguments for parameters on the command line. That way, you can reuse a saved query without having to edit it. The double square brackets are required.

If you have several macro substitutions, you can save them to a file. The file must contain one line per substitution, and each line must be in the format [[PARAM]]=ARG.

Example

In the following example, the variable STOREVARIABLE is used in a saved query, instead of a constant, such as 2:

<sel value="(store='[[STOREVARIABLE]]')"

To assign a value of 2 to STOREVARIABLE, call the saved query and set STOREVARIABLE = 2:

$ tendo -u [USERNAME] [TABLE] @[QUERYFILE] -[[STOREVARIABLE]]=2