0
0
RhSolutions-Api/RhSolutions.Deploy/database/init-database.sql
Sergey Chebotar da94ed6d89 Init commit
2022-12-14 09:53:10 +03:00

25 lines
772 B
SQL

CREATE TABLE IF NOT EXISTS "__EFMigrationsHistory" (
"MigrationId" character varying(150) NOT NULL,
"ProductVersion" character varying(32) NOT NULL,
CONSTRAINT "PK___EFMigrationsHistory" PRIMARY KEY ("MigrationId")
);
START TRANSACTION;
CREATE TABLE "Products" (
"Id" integer GENERATED BY DEFAULT AS IDENTITY,
"ProductSku" text NULL,
"DeprecatedSkus" text[] NOT NULL,
"Name" text NOT NULL,
"ProductLine" text NULL,
"IsOnWarehouse" boolean NULL,
"ProductMeasure" integer NOT NULL,
"DeliveryMakeUp" double precision NULL,
"Price" numeric(8,2) NOT NULL,
CONSTRAINT "PK_Products" PRIMARY KEY ("Id")
);
INSERT INTO "__EFMigrationsHistory" ("MigrationId", "ProductVersion")
VALUES ('20221201071323_Init', '7.0.0');
COMMIT;