Variable Usage
Fortran variables declared to EQUEL can substitute for most elements of EQUEL statements that are not keywords. Of course, the variable and its data type must make sense in the context of the element. The generic uses of host language variables in EQUEL statements are discussed further in the QUEL Reference Guide. The following discussion covers only the usage issues particular to Fortran language variable types.
You must verify that the statement using the variable is in the scope of the variable's declaration. For a discussion of variables in an EQUEL/Fortran program, see
The Scope of Variables. As an example, the following
retrieve statement uses the variables "namvar" and "numvar" to receive data, and the variable "idno" as an expression in the
where clause:
## retrieve (namvar = employee.empname,
## numvar = employee.empnum) where
## employee.empnum = idno