Default Values
  • References/Database/PostgreSQL/Data Definition

A column can be assigned a default value. When a new row is created and no values are specified for some of the columns, those columns will be filled with their respective

2025-01-10 15:47:30
Inheritance
  • References/Database/PostgreSQL/Data Definition

PostgreSQL implements table inheritance, which can be a useful tool for database designers. (SQL:1999 and later define a type inheritance feature

2025-01-10 15:47:30
Modifying Tables
  • References/Database/PostgreSQL/Data Definition

When you create a table and you realize that you made a mistake, or the requirements of the application change, you can drop the table and create it again. But this is not

2025-01-10 15:47:30
System Columns
  • References/Database/PostgreSQL/Data Definition

Every table has several system columns that are implicitly defined by the system. Therefore, these names cannot be used as names of user-defined columns

2025-01-10 15:47:30
Table Basics
  • References/Database/PostgreSQL/Data Definition

A table in a relational database is much like a table on paper: It consists of rows and columns. The number and order of the columns is fixed, and each column has a name. The

2025-01-10 15:47:30
Schemas
  • References/Database/PostgreSQL/Data Definition

A PostgreSQL database cluster contains one or more named databases. Users and groups of users are shared across the entire cluster, but no

2025-01-10 15:47:30
Constraints
  • References/Database/PostgreSQL/Data Definition

Data types are a way to limit the kind of data that can be stored in a table. For many applications, however, the constraint they provide is too coarse. For example, a column

2025-01-10 15:47:30
Partitioning
  • References/Database/PostgreSQL/Data Definition

PostgreSQL supports basic table partitioning. This section describes why and how to implement partitioning as part of your database design

2025-01-10 15:47:30
Dependency Tracking
  • References/Database/PostgreSQL/Data Definition

When you create complex database structures involving many tables with foreign key constraints, views, triggers, functions, etc. you implicitly create a net of dependencies

2025-01-10 15:47:30
Privileges
  • References/Database/PostgreSQL/Data Definition

When an object is created, it is assigned an owner. The owner is normally the role that executed the creation statement. For most kinds of objects, the initial state is that

2025-01-10 15:47:30