Previous Next JavaScript must be enabled to correctly display this content

## 4 Introducing Oracle NoSQL Database Namespaces

You can create one or more global namespaces to extend table identification. Namespaces permit tables with the same name to exist in your database store. To access such tables from the command line, or with DDL commands, use a fully-qualified table name with the table preceded by its namespace, followed with a colon (:), such as `ns1:table1`.

As with tables, you grant authorization permissions to determine who can access both the namespace and the tables within them. After your namespaces exist, you can create any number of parent and child tables within the namespace, such as `ns1:table1.child1`.

There is a default Oracle NoSQL Database namespace, called `sysdefault`. For new installations, all tables are assigned to the default `sysdefault` namespace, until or unless you create other namespaces, and create new tables within them. After upgrading from an earlier Oracle NoSQL Database release, all existing tables become part of the default `sysdefault` namespace automatically. You cannot change an existing table’s namespace.

Tables in the `sysdefault` namespace do not require further qualification for existing queries. For example, using a basic SQL table query does not require the default namespace prefix (`sysdefault:tablename`), for SQL access. Also, the `TableAPI.getTable( )` method does not require any updates at existing sites, since it accepts one argument for table name, or two when you are ready to use namespaces. For information see Using and Setting Namespaces.

    select * from salesincome;

Referencing a table name without a namespace prefix (`namespace:`) implies that the table is part of the default, `sysdefault` namespace. However, by creating namespaces, and then tables within them, you can have same name tables, such as the following for a `support_ticket` table:

- `support_ticket`

- `acme:support_ticket`

- `international_abc:support_ticket`

- `international_xyz:support_ticket`

No additional permissions are required for tables in the default `sysdefault` namespace, so existing authentication remains. For example, if you grant user `Joe` permission to access tables `t1`, `t3`, and `t4`, but not `t2`, Joe can still access all tables except `t2` after they are subsumed into the `sysdefault` namespace.