Forum Discussion

SK87's avatar
SK87
Icon for Helper III rankHelper III
4 years ago

Concatenate Summarize Columns

Hi Team,

I have 2 columns as "Whole Number" in which have value from 0-10. Name column name as A, C. I need to prepare one measure/column which will act as a slicer of all these 2 columns as 1. Based on this the selection of other brands would be done and their respective values would be shown.

 

A brand columns contains suppose 5 sub brands and same with C but sub brands could be different.

How I can combine these 2 columns into one or make any measure which acts in same way.

Dataset :

BrandValuesBrandABrandC
N70.205
N70.200
N74.105
N74.100
N70.205
N70.200
N67.605
N67.600
C66.301
C66.300
C88.401
C88.400
C98.801
C98.800
C83.201
C83.200
C13001
C13000
C122.201
C122.200
C92.301
C92.300
C93.601
C93.600
C83.201
C83.200
C59.801
CG7.802
CG9.102
CG11.702
CG11.702
CG11.702
CG10.402
CG16.902
CG14.302
CG14.302
CG1302
CG16.902
CG23.402
CG24.702
CG27.302
CG2602
CG27.302
CG3902
CG44.202
CG37.702
CG31.202
A41.610
A41.610
A42.910
A42.910
A37.710
A44.210
AD71.520
AD7820
AD76.720
AD67.620
AD74.120
CO57.230
CO57.230
CO58.530
N9140
N92.340
N92.340
P106.650
P102.750
P97.550
P94.950
P96.250
P89.750
P98.850
P93.650
R96.260
R79.360
R80.660
R81.960
R81.960

KIndly suggest

7 Replies

  • tamerj1's avatar
    tamerj1
    Icon for Community Champion rankCommunity Champion

    SK87 
    If I correctly understand then create a calculated column

    TableName[BrandA] & TableName[BrandB]

    Then use it in the slicer

    • SK87's avatar
      SK87
      Icon for Helper III rankHelper III

      Thanks for your response, but unable to get the solution.

      I basically want to create a combined slicer from Brand A & Brand

      • tamerj1's avatar
        tamerj1
        Icon for Community Champion rankCommunity Champion

        SK87 
        Also not sure if I correctly understand the requirement. However this is a sample file with the proposed solution https://we.tl/t-vZNbdEGPkU

        First create a filter table:

         

        Brands = 
        SELECTCOLUMNS (
            DISTINCT ( 
                UNION (
                    VALUES ( 'Dataset'[BrandA] ),
                    VALUES ( 'Dataset'[BrandC] )
                )
            ),
            "Brand", [BrandA]
        )

        Create inactive relationships

         

        Then create this filter measure and place it in the filter pane of the visual

         

        Total Value = 
        VAR BrandAValue =
            CALCULATE (
                SUM ( 'Dataset'[Values] ),
                USERELATIONSHIP ( 'Dataset'[BrandA], 'Brands'[Brand] )
            )
        VAR BrandCValue =
            CALCULATE (
                SUM ( 'Dataset'[Values] ),
                USERELATIONSHIP ( 'Dataset'[BrandC], 'Brands'[Brand] )
            )
        RETURN
            BrandAValue + BrandCValue