Owner name

The owner name specifies the owner of a database object. Use this segment whenever you see a reference to Owner Name in a syntax diagram.


Owner Name

1 "owner"
1  owner 
1 1 'owner'
  • 1 HCL OneDB™ extension
Element Description Restrictions Syntax
owner User name of the owner of an object in a database Maximum length is 32 bytes Must conform to the rules of your operating system.


In an ANSI-compliant database, you must specify the owner of any database object that you do not own. In reference to the owner of database objects, the ANSI/ISO synonym for owner name is authorization identifier. (In reference to schema objects, however, the ANSI/ISO term for what the HCL OneDB documentation calls an owner name is schema name.)

In databases that are not ANSI-compliant, the owner name is optional. You do not need to specify owner when you create database objects or use data access statements. If you do not specify owner when you create a database object, the database server assigns your login name as the owner of the object, in most cases. For exceptions to this rule, see Ownership of Created Database Objects in the CREATE FUNCTION statement description, and Ownership of Created Database Objects in the CREATE PROCEDURE statement description. When a DDL statement in an owner-privileged UDR creates a new database object, the owner of the routine (rather than the user who executes it, if that user is not the owner of the routine) becomes the owner of the new database object.

If you specify owner in data-access statements, the database server checks it for correctness. Without quotation marks, owner is case insensitive. The following four queries all can access data from the table kaths.tab1:
SELECT * FROM kaths.tab1;
SELECT * FROM Kaths.tab1;

In an ANSI-compliant database, only the owner of the table, user kaths, can issue the first of these example queries, which specifies an unqualified table name, but any user who holds the Select privilege on tab1 can issue that query in a database that is not ANSI-compliant. For more information about owner names in ANSI-compliant databases, see ANSI-Compliant Database Restrictions and Case Sensitivity.

A role that the CREATE ROLE statement declares is an authorization identifier, and is therefore subject to the syntax restrictions on owner names, but a role cannot be the owner of a database object. Similarly, the keyword PUBLIC, which specifies the group of all users, cannot be the owner of a database object, except in the special cases of the sysdbopen( ) and sysdbclose( ) procedures. For more information about these built-in session configuration UDRs, see Session Configuration Procedures.