summaryrefslogtreecommitdiffhomepage
path: root/cloud/core/src/schema/account.sql.ts
blob: 1733f0a1568411247372604c976e097bbcc7c417 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
import { pgTable, uniqueIndex, varchar } from "drizzle-orm/pg-core"
import { id, timestamps } from "../drizzle/types"

export const AccountTable = pgTable(
  "account",
  {
    id: id(),
    ...timestamps,
    email: varchar("email", { length: 255 }).notNull(),
  },
  (table) => [uniqueIndex("email").on(table.email)],
)