From a0b3e5f8b5faf110f3ca9534a2e552896ce58297 Mon Sep 17 00:00:00 2001
From: Santo Cariotti <santo@dcariotti.me>
Date: Fri, 12 Mar 2021 19:27:56 +0100
Subject: chapter5: use uuid instead of serial

---
 chapters/physic.tex | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)

(limited to 'chapters/physic.tex')

diff --git a/chapters/physic.tex b/chapters/physic.tex
index 1e923a9..2521f4d 100644
--- a/chapters/physic.tex
+++ b/chapters/physic.tex
@@ -1,7 +1,7 @@
 Qui di seguito è riportato il \verb|dump| in SQL per la creazione delle tabelle all'interno di PostgreSQL
 \begin{lstlisting}[language=SQL]
 CREATE TABLE "repository" (
-    id serial PRIMARY KEY NOT NULL,
+    id uuid PRIMARY KEY NOT NULL,
     url varchar(255) UNIQUE NOT NULL,
     created_date timestamp NOT NULL,
     updated_date timestamp NOT NULL,
@@ -26,9 +26,9 @@ CREATE TABLE "commit" (
 );
 
 CREATE TABLE "branch" (
-    id serial PRIMARY KEY NOT NULL,
+    id uuid PRIMARY KEY NOT NULL,
     name varchar(120) NOT NULL,
-    repository_id integer REFERENCES repository(id) NOT NULL,
+    repository_id uuid REFERENCES repository(id) NOT NULL,
     head varchar(40) REFERENCES commit(hash) NULL
 );
 \end{lstlisting}
\ No newline at end of file
-- 
cgit v1.2.3-18-g5258

