Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now
I have a column with different usernames. some contain some prefixes such as "DOMAIN\" and others dont have these prefixes.
I want a custom column that attaches a text if X is something. Exactly like this :
Desired output :
if Name starts with 'NT SERVICE' or 'NT Authority' then type 'SQL System'
if Name starts with 'DOMAIN\' then type 'Windows Authentification'
if Name starts does NOT start with "DOMAIN" - then type SQL Authentification'
how can I achieve this? I would like to create a custom-column preferably.
thanks!
Solved! Go to Solution.
Hi @aso1 ,
Try this for a custom column on Power Query:
if Text.StartsWith(Text.Upper([Column1]), "NT SERVICE")
or Text.StartsWith(Text.Upper([Column1]), "NT AUTHORITY")
then "SQL System"
else
if Text.StartsWith(Text.Upper([Column1]), "DOMAIN\") then
"Windows Authentication"
else "SQL Authentication"
Hi @aso1 ,
Try this for a custom column on Power Query:
if Text.StartsWith(Text.Upper([Column1]), "NT SERVICE")
or Text.StartsWith(Text.Upper([Column1]), "NT AUTHORITY")
then "SQL System"
else
if Text.StartsWith(Text.Upper([Column1]), "DOMAIN\") then
"Windows Authentication"
else "SQL Authentication"
HI @aso1 ,
You can create a calculated column using DAX as follows:
A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.
Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.
| User | Count |
|---|---|
| 47 | |
| 36 | |
| 27 | |
| 15 | |
| 15 |
| User | Count |
|---|---|
| 58 | |
| 56 | |
| 38 | |
| 21 | |
| 21 |