dwyl / learn-postgresql

🐘 Learn how to use PostgreSQL and Structured Query Language (SQL) to store and query your relational data. 🔍
212 stars 23 forks source link

Rename path to url in logs table in Example App #65

Closed nelsonic closed 5 years ago

nelsonic commented 5 years ago

At present we have a url field/column in the orgs and repos tables: radar-er-diagram But in logs we still use the word path this is an unnecessary confusion, let's rename/refactor.

Todo

nelsonic commented 5 years ago

Before:

CREATE TABLE IF NOT EXISTS "logs" (
  "id" SERIAL PRIMARY KEY,
  "inserted_at" TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
  "path" VARCHAR(255) NOT NULL,
  "next_page" VARCHAR(255) DEFAULT NULL
);

After:

CREATE TABLE IF NOT EXISTS "logs" (
  "id" SERIAL PRIMARY KEY,
  "inserted_at" TIMESTAMP NOT NULL DEFAULT CURRENT_TIMESTAMP,
  "url" VARCHAR(255) NOT NULL,
  "next_page" VARCHAR(255) DEFAULT NULL
);
nelsonic commented 5 years ago

Done ✅ radar-er-diagrm-logs-url