repo.Measure - V

type: V ( view ), modify_date: 2021-11-28 10:57:13

RepoObject_guid: DFF27B65-9D0F-EC11-8518-A81E8446D5B0

Description

Examples

Entity Diagram

entity-repo.measure

Columns

Table 1. Columns of repo.Measure - V
PK Column Name Data Type NULL? ID

nvarchar(max)

NULL

nvarchar(max)

NULL

bit

NULL

nvarchar(517)

NULL

nvarchar(638)

NOT NULL

uniqueidentifier

NOT NULL

nvarchar(max)

NULL

nvarchar(max)

NULL

nvarchar(500)

NULL

nvarchar(max)

NULL

nvarchar(max)

NULL

nvarchar(500)

NULL

bit

NULL

nvarchar(500)

NOT NULL

uniqueidentifier

NULL

varchar(9)

NULL

nvarchar(257)

NOT NULL

uniqueidentifier

NOT NULL

nvarchar(128)

NOT NULL

nvarchar(128)

NOT NULL

Foreign Key Diagram

entity_1_1_fk-repo.measure

References

Object Reference Diagram - 1 1

entity_1_1_objectref-repo.measure

Object Reference Diagram - Referenced - 30 0

entity_30_0_objectref-repo.measure

Object Reference Diagram - Referencing - 0 30

entity_0_30_objectref-repo.measure

Column Reference Diagram

entity_1_1_colref-repo.measure

Indexes

idx_Measure__1

idx_Measure__2

idx_Measure__3

idx_Measure__4

Column Details

_

Description

Description

nvarchar(max)

NULL

Expression

Expression

nvarchar(max)

NULL

is_ssas

is_ssas

bit

NULL

Measure_fullname

Measure_fullname

nvarchar(517)

NULL

Description

quotename([databasename])+'.')+quotename([tables_measures_name]


Measure_fullname2

Measure_fullname2

nvarchar(638)

NOT NULL

Description

(('.measures.')[tables_measures_name])


Measure_guid

Measure_guid

uniqueidentifier

NOT NULL

measures_description

measures_description

nvarchar(max)

NULL

measures_description_ja

measures_description_ja

nvarchar(max)

NULL

measures_displayFolder

measures_displayFolder

nvarchar(500)

NULL

measures_expression

measures_expression

nvarchar(max)

NULL

measures_expression_ja

measures_expression_ja

nvarchar(max)

NULL

measures_formatString

measures_formatString

nvarchar(500)

NULL

measures_isHidden

measures_isHidden

bit

NULL

measures_name

measures_name

nvarchar(500)

NOT NULL

MeasuresRepoObjekt_guid

MeasuresRepoObjekt_guid

uniqueidentifier

NULL

MeasuresRepoObjekt_name

MeasuresRepoObjekt_name

varchar(9)

NULL

RepoObject_fullname2

RepoObject_fullname2

nvarchar(257)

NOT NULL

Description

(('.')[tables_name])


RepoObject_guid

RepoObject_guid

uniqueidentifier

NOT NULL

RepoObject_name

RepoObject_name

nvarchar(128)

NOT NULL

RepoSchema_name

RepoSchema_name

nvarchar(128)

NOT NULL

sql_modules_definition

repo.Measure - V script
CREATE View repo.Measure
As
Select
    T1.Measure_guid
  , RepoSchema_name         = T1.databasename
  , Description             = Coalesce ( T1.tables_measures_description, T2.descriptions_StrAgg )
  , Expression              = Coalesce ( T1.tables_measures_expression, T3.expressions_StrAgg )
  , is_ssas                 = Cast(1 As Bit)
  , measures_name           = T1.tables_measures_name
  , measures_description    = T1.tables_measures_description
  , measures_description_ja = T1.tables_measures_description_ja
  , measures_displayFolder  = T1.tables_measures_displayFolder
  , measures_expression     = T1.tables_measures_expression
  , measures_expression_ja  = T1.tables_measures_expression_ja
  , measures_formatString   = T1.tables_measures_formatString
  , measures_isHidden       = T1.tables_measures_isHidden
  , T1.Measure_fullname2
  , T1.Measure_fullname
  , T1.RepoObject_fullname2
  , T1.RepoObject_guid
  , RepoObject_name         = T1.tables_name
  --one RepoObjekt_guid per schema, because we create one virtual table '_measures' per schema
  --schema = ssas model
  , T4.MeasuresRepoObjekt_guid
  , T4.MeasuresRepoObjekt_name
From
    ssas.model_json_312_tables_measures_T                        As T1
    Left Outer Join
        ssas.model_json_31211_tables_columns_descriptions_StrAgg As T2
            On
            T2.Measure_guid    = T1.Measure_guid

    Left Outer Join
        ssas.model_json_31221_tables_measures_expressions_StrAgg As T3
            On
            T3.Measure_guid    = T1.Measure_guid

    Left Outer Join
        repo.RepoSchema                                          As T4
            On
            T4.RepoSchema_name = T1.databasename