Move all tables into a schema
All checks were successful
Build and Push Docker Image / build (push) Successful in 7m19s
All checks were successful
Build and Push Docker Image / build (push) Successful in 7m19s
This commit is contained in:
@@ -1,5 +1,5 @@
|
||||
-- +goose Up
|
||||
CREATE TABLE click_logs (
|
||||
CREATE TABLE lss.click_logs (
|
||||
click_id BIGSERIAL PRIMARY KEY,
|
||||
url_id INT NOT NULL REFERENCES urls(url_id) ON DELETE CASCADE,
|
||||
clicked_at TIMESTAMP WITH TIME ZONE NOT NULL DEFAULT CURRENT_TIMESTAMP,
|
||||
@@ -9,8 +9,8 @@ CREATE TABLE click_logs (
|
||||
);
|
||||
|
||||
-- Index to optimize analytics queries for a specific link
|
||||
CREATE INDEX idx_click_logs_url_id ON click_logs(url_id);
|
||||
CREATE INDEX idx_click_logs_url_id ON lss.click_logs(url_id);
|
||||
|
||||
-- +goose Down
|
||||
DROP INDEX idx_click_logs_url_id;
|
||||
DROP TABLE click_logs;
|
||||
DROP TABLE lss.click_logs;
|
||||
Reference in New Issue
Block a user