Database Object
An object is something that has substance within the database. For example, table is an object.
Contents to be stored is different according to the type of database. For table, columns and rows will be stored.
SQL command is not an object.
Naming of Object
Objects have a name. The rule of naming objects is similar to that of columns. (Columns are not objects.)
- Cannot use existing names or reserved words.
- Cannot start with number.
- Cannot use signs except ‘_’.
- Use double quote when not using English.
- Cannot exceed the permitted length.
Do not name meaninglessly. As the name of object has nothing to do with the type of object, you can use a name once across all types.
Schema
Database object is made in ‘schema’. Therefore, database in different schema can have a same name.

Schema is defined by DDL(Data Definition Language) of SQL command. In schema, you can define databases.
Namespace is a container that prevents components from having a same name. For example, database and schema could be considered as namespaces.
All images, except those with separate source indications, are excerpted from lecture materials.
댓글남기기