Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
dellmech
Frequent Visitor

Table and Card only showing data if one value is available (not multiple)

Hi, I'm trying to have the value in a Table and Card ONLY show up when there is only 1 possible value to go there.  If there are multiple values, I want it to be blank or return a message ("N/A")

 

For example: If I choose a country, it may have 4 requirements.  This will show 4 details but I don't want details to show multiple values or the card with the date to show the first or last value of the 4.  I want these visuals to show the value once a requirement is selected.

 

I know you can do a COUNTROWS function but I didn't know if you can somehow utilize that to show data in that Details table and Date card when rows = 1.  

 

Any help would be appreciated!

 

 

dellmech_1-1675805903787.png

 

2 ACCEPTED SOLUTIONS
ryan_mayu
Super User
Super User

@dellmech 

you can try to create a measure

Measure = if(DISTINCTCOUNT('Table'[Details])>1,"N/A",max('Table'[Details]))

and do the same for date card.

1.png

pls see the attachment below





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




View solution in original post

@dellmech 

you can try this

Measure 2 = if(DISTINCTCOUNT('Table'[date])>1,"N/A",FORMAT(max('Table'[date]),"yyyy/mm/dd"))

1.png

 

pls see the attachment below





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




View solution in original post

5 REPLIES 5
ryan_mayu
Super User
Super User

@dellmech 

you can try to create a measure

Measure = if(DISTINCTCOUNT('Table'[Details])>1,"N/A",max('Table'[Details]))

and do the same for date card.

1.png

pls see the attachment below





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




This worked for the details table except the date.  It is returning "N/A" when there are multiple values like I wanted.  However, when there is a single value found...instead of the date showing...it is showing #,0.00

 

Any idea how to fix this?

@dellmech 

you can try this

Measure 2 = if(DISTINCTCOUNT('Table'[date])>1,"N/A",FORMAT(max('Table'[date]),"yyyy/mm/dd"))

1.png

 

pls see the attachment below





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Thank you SO much!

you are welcome





Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Helpful resources

Announcements
RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

MayPowerBICarousel

Power BI Monthly Update - May 2024

Check out the May 2024 Power BI update to learn about new features.

LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.