Table "atomic.person"

ColumnTypeNullableDefaultStorageDescription
"projectId"integernot nullplain
"identityId"character varying(80)not nullextended
"tags"text[]extended
"username"character varying(32)extended
"avatarURL"character varying(200)extended
"userRole"character varying(32)extended
"email"character varying(255)extended
"phone"character varying(255)extended
"firstName"character varying(32)extended
"lastName"character varying(32)extended
"gender"textextended
"birthDate"dateplain
"totalSpend"integerplain
"plan"character varying(32)extended
"geoLat"numeric(12,3)main
"geoLng"numeric(12,3)main
"firstEncountered"timestamp with time zoneplain
"registeredAt"timestamp with time zoneplain
"traits"jsonbextended
"jurisdiction"character varying(32)extended
"createdAt"timestamp with time zonenow()plain
"updatedAt"timestamp with time zonenow()plain
"companyIds"text[]extended
"stripeCustomerId"character varying(36)extended
"softDeletedAt"timestamp with time zoneplain

Indexes:

"ProjectId_User" PRIMARY KEY, btree ("projectId", "identityId")
"Person_companyIds" gin ("companyIds")
"Person_tags" gin (tags)
"person__idx__proj_created_updated_identity" btree ("projectId", "createdAt", "updatedAt", "identityId")
"person__idx__proj_identity_created_updated" btree ("projectId", "identityId", "createdAt", "updatedAt")
"person_projectid_createdat_identityid_index" btree ("projectId", "createdAt", "identityId") CLUSTER
"person_projectid_email_index" btree ("projectId", email)
"person_projectid_updatedat_identityid_index" btree ("projectId", "updatedAt", "identityId")
Check constraints:
"Person_gender_check" CHECK (gender = ANY (ARRAY['male'::text, 'female'::text, 'other'::text]))

Policies:

POLICY "Person__rls_1_policy"
USING (("projectId" = get_user_accessible_project_id()))

Access method:

heap
Last updated on by John Gracey