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

Learn from the best! Meet the four finalists headed to the FINALS of the Power BI Dataviz World Championships! Register now

Reply
AhmadBakr
Helper IV
Helper IV

Error while using Table.TransformColumns

Any one can help why I am getting this error message:

Expression.Error: We cannot apply field access to the type Number.
Details:
Value=1.387
Key=FY2023-CIF

When I use this transformation:

= Table.TransformColumns( #"Replaced Value", { { "FY2023-Jan", each [#"FY2023-CIF"] } } )

 

I want to replace the values in "FY-2023-Jan" column with those in "FY2023-CIF" column

 

1 ACCEPTED SOLUTION
OwenAuger
Super User
Super User

Hi @AhmadBakr 

Table.TransformColumns only passes the value in the column being transformed as an argument to the function provided in the 2nd argument. This means that it cannot reference values in columns other than the one being transformed.

 

However, you can use Table.ReplaceValue like this:

= Table.ReplaceValue(#"Replaced Value", each [#"FY2023-Jan"], (_) as number => [#"FY2023-CIF"], Replacer.ReplaceValue, {"FY2023-Jan"})

 

See here.

 

Does this work for you?

 

Regards


Owen Auger
Did I answer your question? Mark my post as a solution!
Blog
LinkedIn

View solution in original post

2 REPLIES 2
AhmadBakr
Helper IV
Helper IV

@OwenAuger thank you very much for the info and the workaround.

 

Pardon my late response, I have been extremly overloaded and working late nights. This is the first time I log into the forum since I posted the question.

OwenAuger
Super User
Super User

Hi @AhmadBakr 

Table.TransformColumns only passes the value in the column being transformed as an argument to the function provided in the 2nd argument. This means that it cannot reference values in columns other than the one being transformed.

 

However, you can use Table.ReplaceValue like this:

= Table.ReplaceValue(#"Replaced Value", each [#"FY2023-Jan"], (_) as number => [#"FY2023-CIF"], Replacer.ReplaceValue, {"FY2023-Jan"})

 

See here.

 

Does this work for you?

 

Regards


Owen Auger
Did I answer your question? Mark my post as a solution!
Blog
LinkedIn

Helpful resources

Announcements
Power BI DataViz World Championships carousel

Power BI DataViz World Championships - June 2026

A new Power BI DataViz World Championship is coming this June! Don't miss out on submitting your entry.

Join our Fabric User Panel

Join our Fabric User Panel

Share feedback directly with Fabric product managers, participate in targeted research studies and influence the Fabric roadmap.

March Power BI Update Carousel

Power BI Community Update - March 2026

Check out the March 2026 Power BI update to learn about new features.