addresses
Billing and shipping addresses linking accounts to contacts.
| Name | Type | Nullable | Default Value | Notes |
|---|---|---|---|---|
PKID | bigint | Address ID | ||
creator | integer | Creator user ID (defaults to authenticated user on creation) | ||
creationdate | bigint | date_part('epoch', now()) | Creation date and time as a Unix timestamp (defaults to current date and time on creation) | |
lastmodified | bigint | date_part('epoch', now()) | Last modification date and time as a Unix timestamp (auto-reset on modification) | |
account accounts.ID | integer | Account ID (**dependency**) | ||
contact contacts.ID | integer | Contact ID | ||
type | smallint | 0 | Address type (`0`=BILLING_SHIPPING, `1`=BILLING_BILLING, `2`=PROCUREMENT_SHIPPING, `3`=PROCUREMENT_BILLING, `4`=COLLECTION, `5`=BILLING_SELLER, `6`=PROCUREMENT_SELLER) | |
default | smallint | 0 | Default for this address type |
| Name | Unique | Nulls Distinct | Primary | Partial | Method | Keys |
|---|---|---|---|---|---|---|
| fk_addresses_contact | btree | contact | ||||
| pk_addresses | btree | ID | ||||
| u_addresses_account_contact_type | btree | account, contact, type, +default |
| Name | Type |
|---|---|
| dc_addresses_type | check |
| fk_addresses_account | foreign_key |
| fk_addresses_contact | foreign_key |
| pk_addresses | primary_key |
| u_addresses_account_contact_type | unique |
| Name | Type | Events | Function | Definition |
|---|---|---|---|---|
| tiu_addresses_default | after | insert, update | ftiu_addresses_default |
Loading...