173 Foreign Key Constraints
| Constraint Name | Child Column | Parent Column | Delete Rule | ||||
|---|---|---|---|---|---|---|---|
| customers_to_tags_tag_id_fkey |
|
|
Restrict delete | ||||
| customers_to_tags_entity_id_fkey |
|
|
Restrict delete | ||||
| customers_custom_fields_values_date_custom_field_id_fkey |
|
|
Restrict delete | ||||
| customers_custom_fields_values_date_entity_id_fkey |
|
|
Restrict delete | ||||
| customers_custom_fields_values_select_entity_id_fkey |
|
|
Restrict delete | ||||
| customers_custom_fields_values_select_custom_field_id_fkey |
|
|
Restrict delete | ||||
| customers_custom_fields_values_select_enum_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_checkbox_entity_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_checkbox_custom_field_id_fkey |
|
|
Restrict delete | ||||
| companies_notes_call_in_note_id_fkey |
|
|
Restrict delete | ||||
| customers_notes_sms_in_note_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_select_entity_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_select_custom_field_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_select_enum_id_fkey |
|
|
Restrict delete | ||||
| customers_responsible_user_id_fkey |
|
|
Restrict delete | ||||
| unsorted_metadata_forms_uid_fkey |
|
|
Restrict delete | ||||
| unknown_events_entity_type_fkey |
|
|
Restrict delete | ||||
| contacts_notes_call_in_note_id_fkey |
|
|
Restrict delete | ||||
| customers_notes_service_message_note_id_fkey |
|
|
Restrict delete | ||||
| unsorted_metadata_chats_uid_fkey |
|
|
Restrict delete | ||||
| leads_notes_call_out_note_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_date_entity_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_date_custom_field_id_fkey |
|
|
Restrict delete | ||||
| statuses_pipeline_id_fkey |
|
|
Restrict delete | ||||
| custom_fields_type_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_chained_list_entity_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_chained_list_custom_field_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_chained_list_entity_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_chained_lis_custom_field_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_smart_address_enum_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_smart_addre_custom_field_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_smart_address_entity_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_chained_list_entity_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_chained_list_custom_field_id_fkey |
|
|
Restrict delete | ||||
| customers_notes_call_in_note_id_fkey |
|
|
Restrict delete | ||||
| leads_loss_reason_id_fkey |
|
|
Restrict delete | ||||
| leads_status_id_pipeline_id_fkey |
|
|
Restrict delete | ||||
| leads_responsible_user_id_fkey |
|
|
Restrict delete | ||||
| leads_pipeline_id_fkey |
|
|
Restrict delete | ||||
| customers_custom_fields_values_chained_lis_custom_field_id_fkey |
|
|
Restrict delete | ||||
| customers_custom_fields_values_chained_list_entity_id_fkey |
|
|
Restrict delete | ||||
| users_role_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_text_entity_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_text_custom_field_id_fkey |
|
|
Restrict delete | ||||
| companies_notes_message_cashier_note_id_fkey |
|
|
Restrict delete | ||||
| leads_to_tags_entity_id_fkey |
|
|
Restrict delete | ||||
| leads_to_tags_tag_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_numeric_custom_field_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_numeric_entity_id_fkey |
|
|
Restrict delete | ||||
| unsorted_metadata_mail_uid_fkey |
|
|
Restrict delete | ||||
| leads_notes_call_in_note_id_fkey |
|
|
Restrict delete | ||||
| company_to_contacts_company_id_fkey |
|
|
Restrict delete | ||||
| company_to_contacts_contact_id_fkey |
|
|
Restrict delete | ||||
| contacts_notes_link_followed_note_id_fkey |
|
|
Restrict delete | ||||
| customers_notes_call_out_note_id_fkey |
|
|
Restrict delete | ||||
| customers_notes_note_type_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_legal_entity_entity_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_legal_entity_custom_field_id_fkey |
|
|
Restrict delete | ||||
| companies_responsible_user_id_fkey |
|
|
Restrict delete | ||||
| customers_notes_attachment_note_id_fkey |
|
|
Restrict delete | ||||
| companies_notes_extended_service_message_note_id_fkey |
|
|
Restrict delete | ||||
| leads_notes_common_note_id_fkey |
|
|
Restrict delete | ||||
| contacts_notes_geolocation_note_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_multitext_entity_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_multitext_enum_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_multitext_custom_field_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_numeric_custom_field_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_numeric_entity_id_fkey |
|
|
Restrict delete | ||||
| companies_notes_link_followed_note_id_fkey |
|
|
Restrict delete | ||||
| contacts_notes_service_message_note_id_fkey |
|
|
Restrict delete | ||||
| customers_notes_amomail_message_note_id_fkey |
|
|
Restrict delete | ||||
| leads_notes_service_message_note_id_fkey |
|
|
Restrict delete | ||||
| companies_to_tags_tag_id_fkey |
|
|
Restrict delete | ||||
| companies_to_tags_entity_id_fkey |
|
|
Restrict delete | ||||
| leads_notes_link_followed_note_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_text_entity_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_text_custom_field_id_fkey |
|
|
Restrict delete | ||||
| contacts_notes_call_out_note_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_select_custom_field_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_select_entity_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_select_enum_id_fkey |
|
|
Restrict delete | ||||
| customers_notes_geolocation_note_id_fkey |
|
|
Restrict delete | ||||
| leads_notes_attachment_note_id_fkey |
|
|
Restrict delete | ||||
| companies_notes_amomail_message_note_id_fkey |
|
|
Restrict delete | ||||
| contacts_responsible_user_id_fkey |
|
|
Restrict delete | ||||
| events_event_type_fkey |
|
|
Restrict delete | ||||
| events_entity_type_fkey |
|
|
Restrict delete | ||||
| unsorted_metadata_sip_uid_fkey |
|
|
Restrict delete | ||||
| events_custom_fields_values_entity_type_fkey |
|
|
Restrict delete | ||||
| contacts_to_tags_tag_id_fkey |
|
|
Restrict delete | ||||
| contacts_to_tags_entity_id_fkey |
|
|
Restrict delete | ||||
| contacts_notes_message_cashier_note_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_checkbox_entity_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_checkbox_custom_field_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_text_entity_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_text_custom_field_id_fkey |
|
|
Restrict delete | ||||
| leads_notes_sms_out_note_id_fkey |
|
|
Restrict delete | ||||
| customers_notes_sms_out_note_id_fkey |
|
|
Restrict delete | ||||
| customers_custom_fields_values_text_entity_id_fkey |
|
|
Restrict delete | ||||
| customers_custom_fields_values_text_custom_field_id_fkey |
|
|
Restrict delete | ||||
| unsorted_pipeline_id_fkey |
|
|
Restrict delete | ||||
| unsorted_category_id_fkey |
|
|
Restrict delete | ||||
| unsorted_lead_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_legal_entity_entity_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_legal_entit_custom_field_id_fkey |
|
|
Restrict delete | ||||
| customers_notes_message_cashier_note_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_date_custom_field_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_date_entity_id_fkey |
|
|
Restrict delete | ||||
| companies_notes_sms_in_note_id_fkey |
|
|
Restrict delete | ||||
| customers_to_segments_entity_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_legal_entity_custom_field_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_legal_entity_entity_id_fkey |
|
|
Restrict delete | ||||
| contacts_notes_common_note_id_fkey |
|
|
Restrict delete | ||||
| customers_notes_extended_service_message_note_id_fkey |
|
|
Restrict delete | ||||
| leads_notes_sms_in_note_id_fkey |
|
|
Restrict delete | ||||
| leads_notes_geolocation_note_id_fkey |
|
|
Restrict delete | ||||
| companies_notes_geolocation_note_id_fkey |
|
|
Restrict delete | ||||
| companies_notes_note_type_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_file_custom_field_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_file_entity_id_fkey |
|
|
Restrict delete | ||||
| companies_notes_call_out_note_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_multitext_entity_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_multitext_enum_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_multitext_custom_field_id_fkey |
|
|
Restrict delete | ||||
| leads_notes_extended_service_message_note_id_fkey |
|
|
Restrict delete | ||||
| company_to_leads_company_id_fkey |
|
|
Restrict delete | ||||
| company_to_leads_lead_id_fkey |
|
|
Restrict delete | ||||
| customers_custom_fields_values_checkbox_custom_field_id_fkey |
|
|
Restrict delete | ||||
| customers_custom_fields_values_checkbox_entity_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_smart_address_enum_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_smart_address_entity_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_smart_address_custom_field_id_fkey |
|
|
Restrict delete | ||||
| leads_notes_message_cashier_note_id_fkey |
|
|
Restrict delete | ||||
| contacts_notes_sms_out_note_id_fkey |
|
|
Restrict delete | ||||
| companies_notes_attachment_note_id_fkey |
|
|
Restrict delete | ||||
| leads_notes_note_type_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_file_entity_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_file_custom_field_id_fkey |
|
|
Restrict delete | ||||
| contacts_notes_extended_service_message_note_id_fkey |
|
|
Restrict delete | ||||
| contacts_notes_attachment_note_id_fkey |
|
|
Restrict delete | ||||
| tasks_entity_type_id_fkey |
|
|
Restrict delete | ||||
| tasks_responsible_user_id_fkey |
|
|
Restrict delete | ||||
| tasks_task_type_id_fkey |
|
|
Restrict delete | ||||
| customers_notes_link_followed_note_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_select_custom_field_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_select_entity_id_fkey |
|
|
Restrict delete | ||||
| companies_custom_fields_values_select_enum_id_fkey |
|
|
Restrict delete | ||||
| company_to_customers_customer_id_fkey |
|
|
Restrict delete | ||||
| company_to_customers_company_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_smart_addres_custom_field_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_smart_address_enum_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_smart_address_entity_id_fkey |
|
|
Restrict delete | ||||
| customers_custom_fields_values_file_custom_field_id_fkey |
|
|
Restrict delete | ||||
| customers_custom_fields_values_file_entity_id_fkey |
|
|
Restrict delete | ||||
| companies_notes_sms_out_note_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_checkbox_entity_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_checkbox_custom_field_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_numeric_entity_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_numeric_custom_field_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_file_entity_id_fkey |
|
|
Restrict delete | ||||
| leads_custom_fields_values_file_custom_field_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_date_entity_id_fkey |
|
|
Restrict delete | ||||
| contacts_custom_fields_values_date_custom_field_id_fkey |
|
|
Restrict delete | ||||
| companies_notes_service_message_note_id_fkey |
|
|
Restrict delete | ||||
| contacts_notes_amomail_message_note_id_fkey |
|
|
Restrict delete | ||||
| contacts_notes_sms_in_note_id_fkey |
|
|
Restrict delete | ||||
| leads_notes_amomail_message_note_id_fkey |
|
|
Restrict delete | ||||
| customers_custom_fields_values_numeric_custom_field_id_fkey |
|
|
Restrict delete | ||||
| customers_custom_fields_values_numeric_entity_id_fkey |
|
|
Restrict delete | ||||
| customers_notes_common_note_id_fkey |
|
|
Restrict delete | ||||
| companies_notes_common_note_id_fkey |
|
|
Restrict delete | ||||
| contacts_notes_note_type_fkey |
|
|
Restrict delete | ||||
| customers_notes_transaction_note_id_fkey |
|
|
Restrict delete |
Check Constraints
| Table | Constraint Name | Constraint |
|---|---|---|
| customers_tags | customers_tags_id_check | ((id > 0)) |
| custom_fields_enums | custom_fields_enums_id_check | ((id > 0)) |
| customers | customers_created_by_check | ((created_by >= 0)) |
| customers | customers_updated_by_check | ((updated_by >= 0)) |
| custom_fields | custom_fields_id_check | ((id > 0)) |
| leads_custom_fields_values_chained_list | leads_custom_fields_values_chained_lis_catalog_element_id_check | ((catalog_element_id > 0)) |
| leads_custom_fields_values_chained_list | leads_custom_fields_values_chained_list_catalog_id_check | ((catalog_id > 0)) |
| custom_fields_types | custom_fields_types_id_check | ((id > 0)) |
| companies_custom_fields_values_chained_list | companies_custom_fields_values_chained_catalog_element_id_check | ((catalog_element_id > 0)) |
| companies_custom_fields_values_chained_list | companies_custom_fields_values_chained_list_catalog_id_check | ((catalog_id > 0)) |
| contacts_custom_fields_values_chained_list | contacts_custom_fields_values_chained__catalog_element_id_check | ((catalog_element_id > 0)) |
| contacts_custom_fields_values_chained_list | contacts_custom_fields_values_chained_list_catalog_id_check | ((catalog_id > 0)) |
| tasks_entity_types | tasks_entity_types_id_check | ((id > 0)) |
| companies_tags | companies_tags_id_check | ((id > 0)) |
| leads | leads_created_by_check | ((created_by >= 0)) |
| leads | leads_id_check | ((id > 0)) |
| leads | leads_labor_cost_check | ((labor_cost >= 0)) |
| leads | leads_price_check | ((price >= 0)) |
| leads | leads_source_id_check | ((source_id > 0)) |
| leads | leads_updated_by_check | ((updated_by >= 0)) |
| customers_custom_fields_values_chained_list | customers_custom_fields_values_chained_catalog_element_id_check | ((catalog_element_id > 0)) |
| customers_custom_fields_values_chained_list | customers_custom_fields_values_chained_list_catalog_id_check | ((catalog_id > 0)) |
| contacts_tags | contacts_tags_id_check | ((id > 0)) |
| unsorted_metadata_mail | unsorted_metadata_mail_message_id_check | ((message_id > 0)) |
| unsorted_metadata_mail | unsorted_metadata_mail_thread_id_check | ((thread_id > 0)) |
| customers_notes | customers_notes_created_by_check | ((created_by >= 0)) |
| customers_notes | customers_notes_id_check | ((id > 0)) |
| customers_notes | customers_notes_responsible_user_id_check | ((responsible_user_id >= 0)) |
| customers_notes | customers_notes_updated_by_check | ((updated_by >= 0)) |
| contacts_custom_fields_values_legal_entity | contacts_custom_fields_values_legal_entity_entity_type_check | ((entity_type > 0)) |
| companies | companies_created_by_check | ((created_by >= 0)) |
| companies | companies_id_check | ((id > 0)) |
| companies | companies_updated_by_check | ((updated_by >= 0)) |
| leads_tags | leads_tags_id_check | ((id > 0)) |
| contacts | contacts_created_by_check | ((created_by >= 0)) |
| contacts | contacts_id_check | ((id > 0)) |
| contacts | contacts_updated_by_check | ((updated_by >= 0)) |
| unsorted_metadata_sip | unsorted_metadata_sip_duration_check | ((duration >= 0)) |
| companies_custom_fields_values_legal_entity | companies_custom_fields_values_legal_entity_entity_type_check | ((entity_type > 0)) |
| leads_custom_fields_values_legal_entity | leads_custom_fields_values_legal_entity_entity_type_check | ((entity_type > 0)) |
| companies_notes | companies_notes_created_by_check | ((created_by >= 0)) |
| companies_notes | companies_notes_id_check | ((id > 0)) |
| companies_notes | companies_notes_responsible_user_id_check | ((responsible_user_id >= 0)) |
| companies_notes | companies_notes_updated_by_check | ((updated_by >= 0)) |
| leads_notes | leads_notes_created_by_check | ((created_by >= 0)) |
| leads_notes | leads_notes_id_check | ((id > 0)) |
| leads_notes | leads_notes_responsible_user_id_check | ((responsible_user_id >= 0)) |
| leads_notes | leads_notes_updated_by_check | ((updated_by >= 0)) |
| tasks | tasks_created_by_check | ((created_by >= 0)) |
| tasks | tasks_duration_check | ((duration >= 0)) |
| tasks | tasks_id_check | ((id > 0)) |
| tasks | tasks_updated_by_check | ((updated_by >= 0)) |
| contacts_notes | contacts_notes_created_by_check | ((created_by >= 0)) |
| contacts_notes | contacts_notes_id_check | ((id > 0)) |
| contacts_notes | contacts_notes_responsible_user_id_check | ((responsible_user_id >= 0)) |
| contacts_notes | contacts_notes_updated_by_check | ((updated_by >= 0)) |