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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
DTreg1
New Member

DAX Distinct String

I am trying to create a new table that returns distinct string from a data table. I created the new table, created a new column with TAGNO = DISTINCT(Table1[tag]) and nothing was returned. Where am I going wrong?

3 REPLIES 3
CPasten
Frequent Visitor

Have you tried with CALCULATETABLE( DISTINCT(Table1[tag]) )

🤔

Abduvali
Skilled Sharer
Skilled Sharer

HI @DTreg1,

 

If you trying to get a column or table, say with unique Ref number or date then the easiest thing is in Edit query Mode:

  1.  Duplicate your table
  2. Remove columns you don't need
  3. Highlight desired column, right click and select remove duplicates

 

This will leave you with just Distinct values in that column and you will have a table with all editable  functions unlike when you use DISTINCT (distinct creates a table but you have limited functionality on it)

 

 

Regards

Abduvali

 

 

Zubair_Muhammad
Community Champion
Community Champion

Hi @DTreg1

 

Did you add it as a Calculated Column?

 

DISTINCT returns a TABLE


Regards
Zubair

Please try my custom visuals

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.