SQL/MX Programming Manual for C and COBOL (G06.24+, H06.03+)

HP NonStop SQL/MX Programming Manual for C and COBOL523627-004
8-1
8
Name Resolution, Similarity Checks,
and Automatic Recompilation
This section covers the following:
Name Resolution on page 8-1
Similarity Checks and Automatic Recompilation on page 8-8
Name Resolution
In a C, C++, and COBOL program, you can use SQL/MX statements to query both
SQL/MP and SQL/MX database objects. This subsection explains how to refer to
SQL/MP and SQL/MX database objects in an C, C++, and COBOL source file and how
the object names are resolved during SQL compilation and run time. See these topics:
Table and View Name References on page 8-1
Precedence of Object Name Qualification on page 8-5
Compile-Time Name Resolution for SQL/MP Objects on page 8-6
Late Name Resolution on page 8-6
Distributed Database Considerations on page 8-7
RDF Considerations on page 8-7
Table and View Name References
When you write a static SQL statement in an embedded SQL program, you have
several choices of how to refer to tables or views:
ANSI Names for SQL/MX Objects on page 8-2
Guardian Names for SQL/MP Objects on page 8-2
SQL/MP Aliases for SQL/MP Objects on page 8-2
DEFINE Names for SQL/MP Objects on page 8-3
PROTOTYPE Host Variables For SQL/MP and SQL/MX Objects on page 8-4
You can fully or partially qualify ANSI logical names, Guardian physical names, and
SQL/MP aliases. For more information, see Precedence of Object Name Qualification
on page 8-5.
Your choice of how to refer to a table or view directly influences how tightly a physical
table is bound to a table or view name in the SQL statement during SQL compilation.