CREATE TABLE IF NOT EXISTS polls (
  id SERIAL,
  title varchar(128) NOT NULL,
  description varchar(16384) NOT NULL,
  datetime timestamp with time zone NOT NULL,
  questions varchar(16384) NOT NULL,
  PRIMARY KEY (id)
);

CREATE TABLE IF NOT EXISTS invitations (
  id SERIAL,
  vanity char(12) NOT NULL,
  comments varchar(1024) NOT NULL,
  created_on timestamp with time zone default current_timestamp,
  poll_id integer NOT NULL,
  PRIMARY KEY (id)
);

CREATE TABLE IF NOT EXISTS responses (
  id SERIAL,
  invitation_code char(12) NOT NULL,
  poll_id bigint NOT NULL,
  response varchar(16384) NOT NULL,
  PRIMARY KEY (id)
);

-- `questions` and `response` are s-expressions.
