Table "public.hosts" Column | Type | Collation | Nullable | Default --------------------+-------------------------+-----------+----------+----------------------- hostid | bigint | | not null | proxy_hostid | bigint | | | host | character varying(128) | | not null | ''::character varying status | integer | | not null | 0 disable_until | integer | | not null | 0 error | character varying(2048) | | not null | ''::character varying available | integer | | not null | 0 errors_from | integer | | not null | 0 lastaccess | integer | | not null | 0 ipmi_authtype | integer | | not null | '-1'::integer ipmi_privilege | integer | | not null | 2 ipmi_username | character varying(16) | | not null | ''::character varying ipmi_password | character varying(20) | | not null | ''::character varying ipmi_disable_until | integer | | not null | 0 ipmi_available | integer | | not null | 0 snmp_disable_until | integer | | not null | 0 snmp_available | integer | | not null | 0 maintenanceid | bigint | | | maintenance_status | integer | | not null | 0 maintenance_type | integer | | not null | 0 maintenance_from | integer | | not null | 0 ipmi_errors_from | integer | | not null | 0 snmp_errors_from | integer | | not null | 0 ipmi_error | character varying(2048) | | not null | ''::character varying snmp_error | character varying(2048) | | not null | ''::character varying jmx_disable_until | integer | | not null | 0 jmx_available | integer | | not null | 0 jmx_errors_from | integer | | not null | 0 jmx_error | character varying(2048) | | not null | ''::character varying name | character varying(128) | | not null | ''::character varying flags | integer | | not null | 0 templateid | bigint | | | description | text | | not null | ''::text tls_connect | integer | | not null | 1 tls_accept | integer | | not null | 1 tls_issuer | character varying(1024) | | not null | ''::character varying tls_subject | character varying(1024) | | not null | ''::character varying tls_psk_identity | character varying(128) | | not null | ''::character varying tls_psk | character varying(512) | | not null | ''::character varying proxy_address | character varying(255) | | not null | ''::character varying auto_compress | integer | | not null | 1 Indexes: "hosts_pkey" PRIMARY KEY, btree (hostid) "hosts_1" btree (host) "hosts_2" btree (status) "hosts_3" btree (proxy_hostid) "hosts_4" btree (name) "hosts_5" btree (maintenanceid) Foreign-key constraints: "c_hosts_1" FOREIGN KEY (proxy_hostid) REFERENCES hosts(hostid) "c_hosts_2" FOREIGN KEY (maintenanceid) REFERENCES maintenances(maintenanceid) "c_hosts_3" FOREIGN KEY (templateid) REFERENCES hosts(hostid) ON DELETE CASCADE Referenced by: TABLE "applications" CONSTRAINT "c_applications_1" FOREIGN KEY (hostid) REFERENCES hosts(hostid) ON DELETE CASCADE TABLE "autoreg_host" CONSTRAINT "c_autoreg_host_1" FOREIGN KEY (proxy_hostid) REFERENCES hosts(hostid) ON DELETE CASCADE TABLE "drules" CONSTRAINT "c_drules_1" FOREIGN KEY (proxy_hostid) REFERENCES hosts(hostid) TABLE "group_prototype" CONSTRAINT "c_group_prototype_1" FOREIGN KEY (hostid) REFERENCES hosts(hostid) ON DELETE CASCADE TABLE "host_discovery" CONSTRAINT "c_host_discovery_1" FOREIGN KEY (hostid) REFERENCES hosts(hostid) ON DELETE CASCADE TABLE "host_discovery" CONSTRAINT "c_host_discovery_2" FOREIGN KEY (parent_hostid) REFERENCES hosts(hostid) TABLE "host_inventory" CONSTRAINT "c_host_inventory_1" FOREIGN KEY (hostid) REFERENCES hosts(hostid) ON DELETE CASCADE TABLE "host_tag" CONSTRAINT "c_host_tag_1" FOREIGN KEY (hostid) REFERENCES hosts(hostid) ON DELETE CASCADE TABLE "hostmacro" CONSTRAINT "c_hostmacro_1" FOREIGN KEY (hostid) REFERENCES hosts(hostid) ON DELETE CASCADE TABLE "hosts" CONSTRAINT "c_hosts_1" FOREIGN KEY (proxy_hostid) REFERENCES hosts(hostid) TABLE "hosts" CONSTRAINT "c_hosts_3" FOREIGN KEY (templateid) REFERENCES hosts(hostid) ON DELETE CASCADE TABLE "hosts_groups" CONSTRAINT "c_hosts_groups_1" FOREIGN KEY (hostid) REFERENCES hosts(hostid) ON DELETE CASCADE TABLE "hosts_templates" CONSTRAINT "c_hosts_templates_1" FOREIGN KEY (hostid) REFERENCES hosts(hostid) ON DELETE CASCADE TABLE "hosts_templates" CONSTRAINT "c_hosts_templates_2" FOREIGN KEY (templateid) REFERENCES hosts(hostid) ON DELETE CASCADE TABLE "httptest" CONSTRAINT "c_httptest_2" FOREIGN KEY (hostid) REFERENCES hosts(hostid) ON DELETE CASCADE TABLE "interface" CONSTRAINT "c_interface_1" FOREIGN KEY (hostid) REFERENCES hosts(hostid) ON DELETE CASCADE TABLE "items" CONSTRAINT "c_items_1" FOREIGN KEY (hostid) REFERENCES hosts(hostid) ON DELETE CASCADE TABLE "maintenances_hosts" CONSTRAINT "c_maintenances_hosts_2" FOREIGN KEY (hostid) REFERENCES hosts(hostid) ON DELETE CASCADE TABLE "opcommand_hst" CONSTRAINT "c_opcommand_hst_2" FOREIGN KEY (hostid) REFERENCES hosts(hostid) TABLE "optemplate" CONSTRAINT "c_optemplate_2" FOREIGN KEY (templateid) REFERENCES hosts(hostid) TABLE "screens" CONSTRAINT "c_screens_1" FOREIGN KEY (templateid) REFERENCES hosts(hostid) ON DELETE CASCADE TABLE "task" CONSTRAINT "c_task_1" FOREIGN KEY (proxy_hostid) REFERENCES hosts(hostid) ON DELETE CASCADE TABLE "widget_field" CONSTRAINT "c_widget_field_3" FOREIGN KEY (value_hostid) REFERENCES hosts(hostid) ON DELETE CASCADE