17 lines
460 B
MySQL
17 lines
460 B
MySQL
|
CREATE TABLE public."UserPreference" (
|
||
|
"Id" uuid NOT NULL,
|
||
|
"UserId" uuid NOT NULL,
|
||
|
"Data" json NOT NULL,
|
||
|
"PreferenceType" smallint NOT NULL
|
||
|
);
|
||
|
|
||
|
|
||
|
ALTER TABLE public."UserPreference" OWNER TO dmptool;
|
||
|
|
||
|
ALTER TABLE ONLY public."UserPreference"
|
||
|
ADD CONSTRAINT "UserPreference_pkey" PRIMARY KEY ("Id");
|
||
|
|
||
|
|
||
|
ALTER TABLE ONLY public."UserPreference"
|
||
|
ADD CONSTRAINT userpreference_user_fk FOREIGN KEY ("UserId") REFERENCES public."UserInfo"(id);
|