19 sql how to, Sql how to – Grass Valley RTic v.2.43 User Manual
Page 39

RTic User Manual- document version: 2.43 - 39
19
SQL how to
•
Insert a Process > ADOSQL object.
•
Double-click the object to edit.
•
In the ODBC source box, select the ODBC Source.
If not listed in the dropdown menu, first specify a source via Start > Settings Administrative tools >
Data sources (ODBC) or another tool.
•
If applicable, specify a user and password for database.
•
Specify a query. The query can be:
•
Fixed
Define a query in the ADOSQL object.
•
Dynamic
The ADOSQL object defines a query with dynamic references ($1, $2, etcetera). Values are
grabbed from a different source that is linked to the ADOSQL object. Specify the separation
sign that separates the values (if more than one) in the Separator string box.
Example:
•
The ADOSQL object defines the query: select * from $1 where $2='$3'
•
The separator string is: ,
•
Input for the query is grabbed from another source.
•
Input is: Employee, Department, IT
•
Resulting in query: grab all from table Employee where Department=IT
Quotes
Note that for some database types (references to) text strings in queries must be enclosed in (single)
quotes.
Test grab
Always test grab to test the query.