The SQL path is an ordered list of collection names. The database manager uses the path to resolve the collection name for unqualified data type names (both built-in and distinct types), function names, and procedure names that appear in any context other than as the main object of a CREATE, DROP, COMMENT ON, GRANT or REVOKE statement. Searching through the path from left to right, the database manager implicitly qualifies the object name with the first collection name in the path that contains the same object with the same unqualified name. For procedures, the database manager selects a matching procedure name only if the number of parameters is also the same. For functions, the database manager uses a process called function resolution in conjunction with the SQL path to determine which function to choose because several functions with the same name can reside in a collection. (For details, see Function Resolution.)
For example, if the SQL path is SMITH, XGRAPHIC, QSYS, QSYS2 and an unqualified distinct type name MYTYPE was specified, the database manager looks for MYTYPE first in collection SMITH, then XGRAPHIC, and then QSYS and QSYS2.
The path used is determined as follows: