For every label – QuickLabel PowerForms User Manual
Page 14

- 14 -
l
When you use commands INSERT, UPDATE or DELETE the variable will contain the
numerical value, which represents the number of the rows affected by the command.
You can use this result for execution tracking. If the result is 0, no updates were done in
the database.
l
When you use command SELECT the variable will contain the result returned from the
database server.
The result for SELECT command can be:
l
Value of a single field: in this case your SQL statement is written to return just single
field from one record field.
Sample statement:
SELECT MyField FROM dbTable WHERE ID = 1
Result: If there is just one record matching the above condition, the value of variable
will be value of field MyField.
l
Values of two or more fields, in one or more records: In this case a dataset is
returned. Each line in the dataset contains data from one record, fields are included in the
line, delimited by comma (,). The first line will contain names of the fields. You will
have to write a script to parse the values into individual values, if you want to use individ-
ual fields in the form.
Sample statement:
SELECT * FROM dbTable WHERE ID = 1 OR ID = 2
The result:
"ID","MyField"
"1","field1"
"2","field2"
Condition: This is a scripting boolean expression. Only two results are possible (True and False).
Use this option to enable current action only when some term is met. The action will be started only
if condition returns True as the result of the expression.
For Every Label
The property defines the list of labels for which all defined actions will be executed.
Fixed values: Define the list of labels.
l
Add: Add labels to the list.
l
Arrow next to the Add button: Add variables to the list. The variables must contain
the path and name of the label.
l
Delete: Remove the selected item from the list.
l
Arrow buttons: Change the order of labels in the list. This is the order in which the
labels are printed.
Variable value: Select one variable that will contain the path and name of the label.
Condition: This is a scripting boolean expression. Only two results are possible (True and False).
Use this option to enable current action only when some term is met. The action will be started only
if condition returns True as the result of the expression.