Consultor Eletrônico



Kbase P126166: What is a SQL-92 named parameter?
Autor   Progress Software Corporation - Progress
Acesso   Público
Publicação   04/10/2007
Status: Unverified

GOAL:

What is a SQL-92 named parameter?

FIX:

A parameterized SQL statement contains parameters, or variables, the values of which can be varied at design time or runtime.
Parameters can replace data values, such as those used in a WHERE clause for comparisons, that appear in an SQL statement.
Ordinarily, parameters stand in for data values passed to the statement.
For example, in the following INSERT statement, values to insert are passed as parameters:
INSERT INTO Country (Name, Capital, Population)

VALUES (:Name, :Capital, :Population)


In this SQL statement, :Name, :Capital, and :Population are placeholders for actual values supplied to the statement at runtime by an application.
Note that the names of parameters begin with a colon.
The colon is required so that the parameter names can be distinguished from literal values.