Host variable usage

Host variables can be used in the following circumstances:

  • In a SELECT, INSERT, UPDATE, or DELETE statement in any place where a number or string constant is allowed.

  • In the INTO clause of a SELECT or FETCH statement.

  • In CONNECT, DISCONNECT, and SET CONNECT statements, a host variable can be used in place of a user ID, password, connection name, or database name.

Host variables can never be used in place of a table name or a column name.