was added entity_type field to entity_views table

This commit is contained in:
viktorbasanets 2018-09-06 13:07:31 +03:00
parent 8ecd9628ca
commit c5827e1b9e
2 changed files with 3 additions and 1 deletions

View File

@ -24,6 +24,7 @@ DROP TABLE IF EXISTS thingsboard.entity_views;
CREATE TABLE IF NOT EXISTS thingsboard.entity_views ( CREATE TABLE IF NOT EXISTS thingsboard.entity_views (
id timeuuid, id timeuuid,
entity_id timeuuid, entity_id timeuuid,
entity_type text,
tenant_id timeuuid, tenant_id timeuuid,
customer_id timeuuid, customer_id timeuuid,
name text, name text,
@ -33,7 +34,7 @@ CREATE TABLE IF NOT EXISTS thingsboard.entity_views (
search_text text, search_text text,
additional_info text, additional_info text,
PRIMARY KEY (id, entity_id, tenant_id, customer_id) PRIMARY KEY (id, entity_id, tenant_id, customer_id)
); );
CREATE MATERIALIZED VIEW IF NOT EXISTS thingsboard.entity_views_by_tenant_and_name AS CREATE MATERIALIZED VIEW IF NOT EXISTS thingsboard.entity_views_by_tenant_and_name AS
SELECT * SELECT *

View File

@ -642,6 +642,7 @@ CREATE TABLE IF NOT EXISTS thingsboard.rule_node (
CREATE TABLE IF NOT EXISTS thingsboard.entity_views ( CREATE TABLE IF NOT EXISTS thingsboard.entity_views (
id timeuuid, id timeuuid,
entity_id timeuuid, entity_id timeuuid,
entity_type text,
tenant_id timeuuid, tenant_id timeuuid,
customer_id timeuuid, customer_id timeuuid,
name text, name text,