Forum Discussion
Companies in different tables.
- Anonymous5 years ago
I have assumed that you have a calendar table that is connected to the date field of both T1 and T2 and you are using this Date field on the matrix visual.
Conteo de empressas canal 1 = DISTINCTCOUNT(T1[Empresa])Conteo de empressas canal 2 = DISTINCTCOUNT(T2[Empresa])Conteo de empressas utilizaron ambos canales el mismo día = VAR Tcanal1 = VALUES(T1[Empresa]) VAR T3 = ADDCOLUMNS( Tcanal1, "Conteo", VAR CE = [Empresa] RETURN IF(CE in VALUES(T2[Empresa]),1,0) ) RETURN SUMX(T3,[Conteo])This will give you the following result.
Because of the filter context from the Calendar table, the cardinality of the tables used in the evaluation of the measures will be limited to that particular date's records. That way the processing load will not be high.
Número de registros de la Tabla 1 en el contexto de filtro actual = COUNTROWS(VALUES(T1))Número de registros de la Tabla 2 en el contexto de filtro actual = COUNTROWS(VALUES(T2))
I have assumed that you have a calendar table that is connected to the date field of both T1 and T2 and you are using this Date field on the matrix visual.
Conteo de empressas canal 1 = DISTINCTCOUNT(T1[Empresa])Conteo de empressas canal 2 = DISTINCTCOUNT(T2[Empresa])
Conteo de empressas utilizaron ambos canales el mismo día =
VAR Tcanal1 = VALUES(T1[Empresa])
VAR T3 =
ADDCOLUMNS(
Tcanal1,
"Conteo",
VAR CE = [Empresa]
RETURN
IF(CE in VALUES(T2[Empresa]),1,0)
)
RETURN
SUMX(T3,[Conteo])This will give you the following result.
Because of the filter context from the Calendar table, the cardinality of the tables used in the evaluation of the measures will be limited to that particular date's records. That way the processing load will not be high.
Número de registros de la Tabla 1 en el contexto de filtro actual = COUNTROWS(VALUES(T1))Número de registros de la Tabla 2 en el contexto de filtro actual = COUNTROWS(VALUES(T2))