guests table

The guests table in the Hotel Booking Database Schema schema has 9 columns, keyed by id. 3 columns in booking_guests, bookings and reviews reference it.

The person who books is not always the person who sleeps there. See booking_guests.

Columns (9)

Columns of the guests table
ColumnTypeConstraintsDescription
iduuidprimary key
emailvarchar(255)unique
first_namevarchar(80)not null
last_namevarchar(80)not null
phonevarchar(32)
date_of_birthdate
nationalitychar(2)
loyalty_numbervarchar(40)unique
created_attimestamptznot null

Indexes (1)

  • (last_name, first_name)

Relationships