Local Substitution Parameters

When you define a query (on a database, for a graphic report, for a data view, as part of a configured process) you can set local substitution parameters in the Substitutions page of the Property Editor. Unlike the global substitutions that are configured and applied across the application, local substitutions are applied on an object-by-object basis, .

When you create a new substitution parameter, its properties are defined in the Substitution Parameter Property Editor.

Identity

Name

The name of the substitution parameter as it will be shown in the Substitution Parameters list of the object. This can be different from the Prompt String but will often be the same.

If the names of the substitution parameters of a macro task are identical to the names of the substitution parameters prompted for by a macro prior to the start of the task, those task substitutions will not be prompted for and the macro task will be executed immediately.

Any task substitution parameters that do not match the name of a macro substitution parameter will be prompted for as usual during the running of that task.

Description

A brief description of the type of value contained by the parameter to clarify the purpose, if necessary.

Input

Response

OK

Finally, click OK to add the new parameter to the Substitutions page of the Property Editor.

Once you have setup your substitution parameters, you can set up your queries in the normal fashion, using questions marks to enclose each Prompt. Note that if the result is text, it will still need to be enclosed in single quotes.

SELECT PROJECT, SITE_ID, END_DEPTH, DATE_STARTED, DATE_COMPLETED

FROM GB_SITE

WHERE PROJECT = '?Select a project?'

AND DATE_STARTED > '?Select start date?'

ORDER BY SITE_ID

For more information, refer to the following topics:

Multiple parameters may also be used when constructing the file paths for configured exports, imports, application calls, etc. A parameter could be configured for a “Project Sub-folder” and another for the “file name”, for example. The path could then be configured as:

“N:\Geodata\? Project Sub-folder?\? file name?”