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
aso1
Helper II
Helper II

si columna de declaración

Tengo una columna con diferentes nombres de usuario. algunos contienen algunos prefijos como "DOMAIN" y otros no tienen estos prefijos.

Quiero una columna personalizada que adjunte un texto si X es algo. Exactamente así :

Salida deseada :

si Name comienza con 'NT SERVICE' o 'NT Authority' escriba 'SQL System'

si Name comienza con 'DOMAIN', escriba 'Windows Authentification'

si Name starts NO comienza con "DOMAIN" - escriba SQL Authentification'

powerbi_customcolumnfor SQL_WindowsUsers.jpg

¿cómo puedo lograr esto? Me gustaría crear una columna personalizada preferiblemente.

¡Gracias!

2 REPLIES 2
camargos88
Community Champion
Community Champion

Hola @aso1 ,

Pruebe esto para una columna personalizada en Power Query:

if Text.StartsWith(Text.Upper([Column1]), "NT SERVICE")
o Text.StartsWith(Text.Upper([Column1]), "NT AUTHORITY")
luego "Sistema SQL"
Más
if Text.StartsWith(Text.Upper([Column1]), "DOMAIN- ") a continuación,
"Autenticación de Windows"
else "Autenticación SQL"



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

Proud to be a Super User!



Pragati11
Super User
Super User

HOLA @aso1 ,

Puede crear una columna calculada utilizando DAX de la siguiente manera:

ifContainsString á IF(CONTAINSSTRING(youTable[Name], "NT SERVICE") ? TRUE() ? CONTAINSSTRING(youTable[Name], "NT Authority") - TRUE(), "SQL System",
IF (CONTAINSSTRING (youTable[Name], "DOMAIN") - TRUE() , "Windows Authentication," "SQL Authentication") )
Gracias
Pragati

Best Regards,

Pragati Jain


MVP logo


LinkedIn | Twitter | Blog YouTube 

Did I answer your question? Mark my post as a solution! This will help others on the forum!

Appreciate your Kudos!!

Proud to be a Super User!!

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.