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
azizimranz
Frequent Visitor

How to concatinate text with some dynamic value

Hi All,

 

My scenario is, need to show a url hyperlink icon based on the environment. i.e. if the environment is staging, url would have ...staging..., and if the environment is production, url would have ...production...

 

I need to set a custom column having a concatination of some hardcoded text with 'this dynamic server environment'

 

Any way of reading the system properties in powerbi, or reading another database table's value in other table and using that value in a function showing custom column?

1 ACCEPTED SOLUTION

You can also choose for a Power Query solution (Query Editor).

If you only have a single value, you can also define a Parameter.

 

Example query code with both alternatives:

 

let
    Source = #table(type table[Environment = text],{{"Env 01"},{"Env 02"}}),
    #"Added Custom" = Table.AddColumn(Source, "Environnment and Server from Table B", each [Environment] & " " & Table.FirstValue(#"Table B")),
    #"Added Custom1" = Table.AddColumn(#"Added Custom", "Environmemnt and Server from parameter", each [Environment] & " " & Server)
in
    #"Added Custom1"

 

Screenshot for parameter definition:

 

Server from parameter.png

Specializing in Power Query Formula Language (M)

View solution in original post

11 REPLIES 11

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.