Aan de slagGa gratis aan de slag

User-level schemas

An important use-case for PostgreSQL schemas is the ability to provide database users with their own group of tables that are only accessible to each individual user, such that users' database access does not interfere with others. In the name of security, this can be taken one step further to separate any production tables from being manipulated by unauthorized users. Schemas allow these divisions to be created without the use of multiple databases which can reduce maintenance requirements for database administrators.

Deze oefening maakt deel uit van de cursus

Creating PostgreSQL Databases

Cursus bekijken

Oefeninstructies

  • Create 3 schemas, one for web developer Ann Simmons, one for data analyst Ty Beck, and one for production data (named production). Use a name_lastname format to name the employee schemas.

Praktische interactieve oefening

Probeer deze oefening eens door deze voorbeeldcode in te vullen.

-- Add a schema for Ann Simmons
CREATE SCHEMA ___;

-- Add a schema for Ty Beck
___ ___ ty_beck;

-- Add a schema for production data
___ ___ ___;
Code bewerken en uitvoeren