From 6b370d17763e0847bfdfeb97dca3c6d191ad1fbb Mon Sep 17 00:00:00 2001 From: CrazyBolillo Date: Sun, 21 Jul 2024 21:56:06 -0600 Subject: [PATCH] feat: update cdr schema It now includes a primary key to make it easier to reference entries in the table. --- internal/sqlc/models.go | 1 + schema.sql | 1 + 2 files changed, 2 insertions(+) diff --git a/internal/sqlc/models.go b/internal/sqlc/models.go index 1bbbcf2..2a0b513 100644 --- a/internal/sqlc/models.go +++ b/internal/sqlc/models.go @@ -1565,6 +1565,7 @@ type AlembicVersion struct { } type Cdr struct { + ID int64 Accountcode pgtype.Text Src pgtype.Text Dst pgtype.Text diff --git a/schema.sql b/schema.sql index 4cafb98..d603e54 100644 --- a/schema.sql +++ b/schema.sql @@ -272,6 +272,7 @@ CREATE TABLE public.alembic_version ( ); CREATE TABLE public.cdr ( + id BIGSERIAL PRIMARY KEY, accountcode character varying(80), src character varying(80), dst character varying(80),