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

Power BI is turning 10! Let’s celebrate together with dataviz contests, interactive sessions, and giveaways. Register now.

Reply
krishna_murthy
Regular Visitor

how to get concatenate for 3 coloms

hi Team,

 

i have requirement here , Requesting please check and do the needful 

 

First NameLast nameSum of Age
Eastpai35
NorthKiran30
RameshKumar35
SouthYesh40
WestLol56

 

i Want result is like ----

 

East Pai , 35

North Kiran ,30

Ramesh Kumar , 35

 

2 ACCEPTED SOLUTIONS

@krishna_murthy 
Below is the DAX code as welll

DAX Code = 
SELECTCOLUMNS(
ADDCOLUMNS(
	Source,"@Col",
Source[First Name] & ","& Source[Last name] & ","& Source[Sum of Age]
),[@Col] )

screenshot

sanalytics_1-1742643418158.png

Let me know if you are looking for pbix file..

 

Hope it helps

 

Regards

sanalytics

View solution in original post

mdaatifraza5556
Solution Specialist
Solution Specialist

Hi @krishna_murthy 

Follow the below steps to achieve it.

1. Step
        Go to Power Query ---> select Add Column ---> click Custom Column ----> Then write the query I wrote below.

Query 
-----------
[First Name] &" "& [Last name]&", "&Text.From([Sum of Age])

mdaatifraza5556_0-1742792870250.png


Result

mdaatifraza5556_1-1742792933980.png

 

View solution in original post

3 REPLIES 3
mdaatifraza5556
Solution Specialist
Solution Specialist

Hi @krishna_murthy 

Follow the below steps to achieve it.

1. Step
        Go to Power Query ---> select Add Column ---> click Custom Column ----> Then write the query I wrote below.

Query 
-----------
[First Name] &" "& [Last name]&", "&Text.From([Sum of Age])

mdaatifraza5556_0-1742792870250.png


Result

mdaatifraza5556_1-1742792933980.png

 

sanalytics
Super User
Super User

@krishna_murthy 
Use below Power query code for your exact output

let
    Source = Table.FromRows(Json.Document(Binary.Decompress(Binary.FromText("i45Wck0sLlHSUSpIzASSxqZKsTrRSn75RSUZQK53ZlFiHkjYACwclJibWgwWL81NLEIoD84vBSuPhMiaQFSHp4IN9snPAZKmZkqxsQA=", BinaryEncoding.Base64), Compression.Deflate)), let _t = ((type nullable text) meta [Serialized.Text = true]) in type table [#"First Name" = _t, #"Last name" = _t, #"Sum of Age" = _t]),
    TypeChanged = Table.TransformColumnTypes(Source,{{"Sum of Age", Int64.Type}}),
    Output =
Table.FromList(
Table.ToList(
    TypeChanged,each Text.Combine( List.Transform(_, each Text.From(_)),","
    )
),Splitter.SplitByNothing())
in
    Output

screenshot below

sanalytics_0-1742642952588.png

 

Let me know if you are ooking for DAX code or not.

 

Hope it helps

 

Regards,

sanalytics

@krishna_murthy 
Below is the DAX code as welll

DAX Code = 
SELECTCOLUMNS(
ADDCOLUMNS(
	Source,"@Col",
Source[First Name] & ","& Source[Last name] & ","& Source[Sum of Age]
),[@Col] )

screenshot

sanalytics_1-1742643418158.png

Let me know if you are looking for pbix file..

 

Hope it helps

 

Regards

sanalytics

Helpful resources

Announcements
Join our Fabric User Panel

Join our Fabric User Panel

This is your chance to engage directly with the engineering team behind Fabric and Power BI. Share your experiences and shape the future.

June 2025 Power BI Update Carousel

Power BI Monthly Update - June 2025

Check out the June 2025 Power BI update to learn about new features.

June 2025 community update carousel

Fabric Community Update - June 2025

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