Page History
...
Include Page | ||||
---|---|---|---|---|
|
Variable Syntax
The variable format supports setting a default value, data type and a few options as in the following example:
...
Part | Default | Description |
---|---|---|
name | Required | Required. This is the name that appear in the prompt window. If multiple variables in a script have the same name, the substitution dialog shows only one and the entered value will be applied to all variables with that name |
value | null | The default value for the variable |
type | none (= literal) | The type of variable: String, Boolean, Integer, Float, Long, Double, BigDecimal, Date, Time and Timestamp. In addition DbVisualizer defines: BinaryData and TextData (for CLOB). This is used to determine how the data should be passed between DbVisualizer and the database server. If no type is specified, it is treated as a literal |
options | none | The options part is used to express certain conditions. Separate these with a whitespace
|
Pre-defined Variables
A few pre-defined DbVisualizer variables can be used anywhere in the SQL. These are replaced with actual values just before the SQL is sent to the DB server.
...
In an sql script, the name on the result set produced by the next SELECT statement can be set with the @set resultset name
command (see Using Client-Side Commands). This result set name is accessible through the variable
${dbvis-resultset-name}$
Variable Substitution in SQL statements
Note |
---|
For variable processing to work in the SQL Commander, make sure the SQL->Enable Parameterized SQL main menu option is checked. |
...
Overview
Content Tools