19 lines
625 B
SQL
19 lines
625 B
SQL
CREATE TABLE "printerData" (
|
|
"printer_id" uuid PRIMARY KEY DEFAULT gen_random_uuid() NOT NULL,
|
|
"humanReadableId" text,
|
|
"name" text NOT NULL,
|
|
"ipAddress" text,
|
|
"port" numeric,
|
|
"status" text,
|
|
"statusText" text,
|
|
"lastTimePrinted" timestamp DEFAULT now() NOT NULL,
|
|
"assigned" boolean DEFAULT false,
|
|
"remark" text,
|
|
"printDelay" numeric,
|
|
"monitorState" boolean DEFAULT false,
|
|
"add_Date" timestamp DEFAULT now(),
|
|
"upd_date" timestamp DEFAULT now()
|
|
);
|
|
--> statement-breakpoint
|
|
DROP TABLE "printers" CASCADE;--> statement-breakpoint
|
|
CREATE UNIQUE INDEX "humanReadableId" ON "printerData" USING btree ("humanReadableId"); |