Any table, view, or SQL procedure can be addressed using a qualified name, by prefixing the name of the object with the name of its containing schema, separated by a dot; e.g.:
If these objects are referenced without a schema, they will be looked for in the user's default schema, if one has been assigned.
The default schema can be overridden within an ODBC/JDBC session by issuing the SET CURRENT SCHEMA command. Once set, the new schema will be used to resolve unqualified names instead of the default schema--the user's default schema will be ignored for the purposes of name resolution.
Each table and view is identified by a name, which must meet the standard naming criteria.
However, in SQL, a pound sign used at the beginning of a table/view name will automatically be replaced by the current user's username, followed by an underscore. This provides a shorthand way for a user to create & reference namespaced tables within a common schema.
For instance, if a user, auser, issues the following query:
The query will be translated into this and executed:
For a list of the reserved words within Kinetica see SQL Reserved Word List.