Skip to content

[BACKEND] Database design #2

@FjjDessoyCaraballo

Description

@FjjDessoyCaraballo

Current table design

This is the current design of our table. We only have one table as it seems unnecessary to add complexity.

CREATE TABLE IF NOT EXISTS bookings (
	id			UUID PRIMARY KEY default get_random_uuid(),
	intra		TEXT NOT NULL,
	room_name	TEXT NOT NULL,
	begin_at	TIMESTAMPTZ NOT NULL,
	end_at		TIMESTAMPTZ NOT NULL,
	is_staff	BOOLEAN NOT NULL DEFAULT FALSE
);

Description of rows

  1. id regular uuid for all insertions;
  2. intra 42 intra username;
  3. room_name name of the meeting room;
  4. begin_at UNIX timestamp declaring the beginning of the booking session;
  5. end_at UNIX timestamp declaring the end of the booking session;
  6. is_staff boolean to separate staff from students (adding admin powers later to cancel bookings).

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type
    No fields configured for issues without a type.

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions