added uuid to moist tables

This commit is contained in:
2024-12-10 17:19:59 -05:00
parent 9ab8961518
commit b3ba9fbe08
9 changed files with 18 additions and 9 deletions

View File

@@ -1,9 +1,10 @@
import { pgTable, integer, varchar, text } from "drizzle-orm/pg-core";
import { pgTable, integer, varchar, text, uuid } from "drizzle-orm/pg-core";
import { sql } from "drizzle-orm";
import { timestamps } from "./helpers/columns.helpers";
export const Build = pgTable("builds", {
id: integer().primaryKey().generatedAlwaysAsIdentity({ name: "build_id_seq", startWith: 1, increment: 1, minValue: 1, maxValue: 2147483647, cache: 1 }),
uuid: uuid().defaultRandom().unique(),
account_id: integer().notNull(),
name: varchar({length:255}).notNull(),
description: text(),