Forum Discussion

harirao's avatar
harirao
Icon for Post Prodigy rankPost Prodigy
5 years ago
Solved

Hide few column in Table

Hi All,

Please note, i have to hide few columns in below table from Product ID Description till Mainstream (like group-by in excel).


Thank you

 

Regards,

 

  • harirao There is no hiding of columns like in Excel. You can turn off word wrap and shrink columns to nothing but that's not going to be dynamic unless you use something like a bookmark. I'm not familiar with Group By functionality in Excel that is dynamic either but not an Excel guru.

  • Anonymous's avatar
    Anonymous
    5 years ago

    Hi harirao 

    In addition to 

    M.Detail1 = IF(SELECTEDVALUE(Slicer[Slicer])="Detail",MAX('Table'[Detail1]),BLANK())
    M.Detail2 = IF(SELECTEDVALUE(Slicer[Slicer])="Detail",SUM('Table'[Detail2]),BLANK())

    Then build a table visual by common columns and measure columns.

    Or you can try to unpivot the columns without Month and FCST Month in power query editor.

    New Table:

    Build a Measure:

    Measure =
    IF (
        HASONEFILTER ( Slicer[Slicer] ),
        IF (
            SELECTEDVALUE ( Slicer[Slicer] ) = "No Detail",
            CALCULATE (
                MAX ( 'Table (2)'[Value.1] ),
                FILTER (
                    'Table (2)',
                    NOT ( 'Table (2)'[Attribute] IN { "Detail1", "Detail2" } )
                )
            ),
            MAX ( 'Table (2)'[Value.1] )
        ),
        BLANK ()
    )

    Build a Matrix 

    Select Detail:

     

    Best Regards,

    Rico Zhou

     

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly. 

  • Anonymous's avatar
    Anonymous
    5 years ago

    Hi harirao 

    Could you tell me if your problem has been solved? If it is, kindly Accept it as the solution. More people will benefit from it. Or you are still confused about it, please provide me with more details about your problem or share me with your pbix file from your Onedrive for Business.

     

    Best Regards,

    Rico Zhou

6 Replies

    • harirao's avatar
      harirao
      Icon for Post Prodigy rankPost Prodigy

      Hello Greg_Deckler,

       

      Thanks for your response, yes i want same number of rows and also whenever a Product ID  is selected want to details should be available/visible something like group-by in excel.

       

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

    harirao There is no hiding of columns like in Excel. You can turn off word wrap and shrink columns to nothing but that's not going to be dynamic unless you use something like a bookmark. I'm not familiar with Group By functionality in Excel that is dynamic either but not an Excel guru.

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi harirao 

    In addition to 

    M.Detail1 = IF(SELECTEDVALUE(Slicer[Slicer])="Detail",MAX('Table'[Detail1]),BLANK())
    M.Detail2 = IF(SELECTEDVALUE(Slicer[Slicer])="Detail",SUM('Table'[Detail2]),BLANK())

    Then build a table visual by common columns and measure columns.

    Or you can try to unpivot the columns without Month and FCST Month in power query editor.

    New Table:

    Build a Measure:

    Measure =
    IF (
        HASONEFILTER ( Slicer[Slicer] ),
        IF (
            SELECTEDVALUE ( Slicer[Slicer] ) = "No Detail",
            CALCULATE (
                MAX ( 'Table (2)'[Value.1] ),
                FILTER (
                    'Table (2)',
                    NOT ( 'Table (2)'[Attribute] IN { "Detail1", "Detail2" } )
                )
            ),
            MAX ( 'Table (2)'[Value.1] )
        ),
        BLANK ()
    )

    Build a Matrix 

    Select Detail:

     

    Best Regards,

    Rico Zhou

     

    If this post helps, then please consider Accept it as the solution to help the other members find it more quickly. 

  • Hi harirao ,

     

    The best way here is to simply turn-off word wrap of both column headers and values and then reduce the width to zero.

    By this way, you will be able to hide the columns from your table visualization while keeping the grouping(or granularity here) intact.

     

    Give a thumbs up if this post helped you in any way and mark this post as solution if it solved your query !!!

  • Anonymous's avatar
    Anonymous
    Not applicable

    Hi harirao 

    Could you tell me if your problem has been solved? If it is, kindly Accept it as the solution. More people will benefit from it. Or you are still confused about it, please provide me with more details about your problem or share me with your pbix file from your Onedrive for Business.

     

    Best Regards,

    Rico Zhou