Referencing host variables in embedded SQL applications
After you have declared
a host variable in your embedded SQL application code, you can reference
it later in the application.
About this task
When you use a host variable in an SQL statement, prefix its name with a colon (:). If you use a host variable in host language programming syntax, omit the colon.
Reference
the host variables using the syntax for the host language that you
are using. The following table provides examples.
| Language | Example Source Code |
|---|---|
| C or C++ | |
| COBOL | |
| FORTRAN | |
| REXX | |