## Notes - Tables ## Tables ```sql CREATE EXTENSION pgcrypto; CREATE TABLE contact_information ( contact_information_id INTEGER PRIMARY KEY, first_name VARCHAR(255), last_name VARCHAR(255), created_at TIMESTAMP WITH TIME ZONE, updated_at TIMESTAMP WITH TIME ZONE ); CREATE TABLE users ( email TEXT PRIMARY KEY, password TEXT NOT NULL, -- hashed, duh last_sign_in_at TIMESTAMP WITH TIME ZONE, created_at TIMESTAMP WITH TIME ZONE, updated_at TIMESTAMP WITH TIME ZONE, ); CREATE TABLE public.groups ( id bigint NOT NULL, "createdAt" timestamp with time zone DEFAULT now() NOT NULL, "updatedAt" timestamp with time zone DEFAULT now(), "groupName" character varying, "ownerId" uuid DEFAULT auth.uid(), "groupDetails" json, "memberIds" uuid[] ); CREATE TABLE public.restaurants ( id integer NOT NULL, name text NOT NULL, location gis.geography(Point,4326) NOT NULL ); ```