Titulaires

This commit is contained in:
2025-11-15 14:33:46 +01:00
parent e7959f13de
commit 110a6cd4b6
2 changed files with 10 additions and 14 deletions

View File

@@ -30,10 +30,10 @@ Création de la table `person`.
```sql
create table person (
"id" bigint primary key references holder(id),
"firstname" text,
"lastname" text,
"birthdate" date
"id" bigint primary key references holder(id) on delete cascade,
"firstname" text not null,
"lastname" text not null,
"birthdate" date not null check (birthdate <= current_date - interval '15 years')
);
```
@@ -41,9 +41,10 @@ create table person (
```sql
create table company (
"id" bigint primary key references holder(id),
"name" text,
"creation_date" date
"id" bigint primary key references holder(id) on delete cascade,
"name" text not null,
"registration_number" text unique not null,
"creation_date" date not null
);
```