Forum Discussion

RAdams's avatar
RAdams
Icon for Helper III rankHelper III
9 years ago
Solved

Only Show Data in Table or Card when Slicer picked

I have an Employee HR table, which contains Employees personal information (First, Middle, Last, SSN, Hire Date, Beneficiaries, etc.).    I created a Full Name column from the First-Last-SSN.    ...
  • Eric_Zhang's avatar
    9 years ago

    RAdams wrote:

    I have an Employee HR table, which contains Employees personal information (First, Middle, Last, SSN, Hire Date, Beneficiaries, etc.). 

     

    I created a Full Name column from the First-Last-SSN. 

     

    What I would like to do is have the Full Name in a slicer that controls what is displayed in a Matrix Table (since some employees have multilpe Beneficiaries and other data) and two other Cards to show SSN and Hire Date.  Only thing is I would like everything (Table & Cards) to only display data when an Employee is selected in the Slicer. 

     

    I looked into using ISFILTERED but it doesn't work in my scenario. 

     

    Anything out there someone may have come across or can someone offer some advice on this? 


    Thanks!

    R


    RAdams

    Create measures as below and put them to cards and matrix. It shall work.

     

    SSN measure =
    IF (
        ISFILTERED ( 'Table'[fullName] ) && HASONEVALUE ( 'Table'[fullName] ),
        LASTNONBLANK ( 'Table'[SSN], "" ),
        BLANK ()
    )
    
    
    HireDate measure =
    IF (
        ISFILTERED ( 'Table'[fullName] ) && HASONEVALUE ( 'Table'[fullName] ),
        LASTNONBLANK ( 'Table'[HireDate], "" ),
        BLANK ()
    )