initial commit
This commit is contained in:
45
database/schema/user.pg.hcl
Normal file
45
database/schema/user.pg.hcl
Normal file
@@ -0,0 +1,45 @@
|
||||
table "users" {
|
||||
schema = schema.public
|
||||
|
||||
column "id" {
|
||||
type = uuid
|
||||
null = false
|
||||
}
|
||||
column "first_name" {
|
||||
type = text
|
||||
}
|
||||
column "last_name" {
|
||||
type = text
|
||||
}
|
||||
column "display_name" {
|
||||
type = text
|
||||
}
|
||||
column "email" {
|
||||
type = text
|
||||
null = false
|
||||
}
|
||||
|
||||
column "created_at" {
|
||||
type = timestamptz
|
||||
default = sql("now()")
|
||||
null = false
|
||||
}
|
||||
|
||||
column "updated_at" {
|
||||
type = timestamptz
|
||||
null = true
|
||||
default = sql("now()")
|
||||
}
|
||||
column "deleted_at" {
|
||||
type = timestamptz
|
||||
null = true
|
||||
}
|
||||
|
||||
primary_key {
|
||||
columns = [column.id]
|
||||
}
|
||||
|
||||
unique "users_email_unique" {
|
||||
columns = [column.email]
|
||||
}
|
||||
}
|
||||
Reference in New Issue
Block a user