Schema: hr
English table: hr.company_accounts
Italian original table: hr.azienda_conti
Description: Company bank accounts used for payments and accounting references.
Overview
- Columns: 9
- Primary key: id
- Outgoing foreign keys: 1
- Incoming foreign keys: 0
- Indexes: 3
Columns
| English column | Italian original column | Type | Null | Default / Generated | Description |
|---|
id | id | integer | NO | | Surrogate primary key. |
ca_id | azc_id | integer | NO | | Company account internal identifier, unique per tenant. |
ca_company_id | azc_az_id | integer | NO | | Reference to the company owning this account. |
ca_description | azc_description | character varying(50) | NO | | Short description of the company account. |
ca_iban | azc_iban | character varying(27) | NO | | IBAN of the company account. |
ca_account_code | azc_account_code | character varying(15) | NO | | Accounting code associated with the company account. |
tenant_id | tenant_id | integer | YES | | Tenant identifier. |
colcustom | colcustom | jsonb | YES | '{}'::jsonb | Custom fields in JSON format. |
_deleted | _deleted | boolean | YES | false | Soft delete flag. |
Relationships
Outgoing foreign keys
| Constraint | Local columns | References | Referenced columns | On update | On delete |
|---|
fk_company_accounts_tenant_id | tenant_id | cloud.tenants | ten_internal_id | RESTRICT | CASCADE |
Referenced by
No incoming foreign keys found.
Constraints
- Primary key:
pk_company_accounts → id
- Unique:
uk_company_accounts_ca_id_tenant → ca_id, tenant_id
Indexes
| Name | Unique | Method | Columns / expression |
|---|
idx_cmpacc_tenant | NO | btree | tenant_id |
idx_cmpacc_tenant_ca | NO | btree | tenant_id, ca_id) WHERE (_deleted = false |
idx_cmpacc_tenant_company | NO | btree | tenant_id, ca_company_id) WHERE (_deleted = false |
Navigation