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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
informer
Helper I
Helper I

column name with Parenthesis = code on error

Hey,

 

This code is on error due to [Volume(24h)]. What is the solution for correcting this error ?

Thanks a lot

 

error.JPG

 

 

= Table.ReplaceValue(#"Clean data Name",
each [Volume(24h)],
each Text.RemoveRange([Volume(24h)],Text.Length([Volume(24h)])-Text.Length([Acronyme]), Text.Length([Acronyme])),
Replacer.ReplaceText,
{"Volume(24h)"}
)

 

 

 

replace+remove.JPG

1 ACCEPTED SOLUTION
DataNinja777
Super User
Super User

Hi @informer ,

 


The issue occurs because column names with special characters, such as parentheses, require special handling in Power Query (M language). In your case, Volume(24h) contains parentheses, so it must be enclosed in square brackets and quoted with a # sign and double quotes. The correct approach is to reference it as #"Volume(24h)" throughout the formula. Here’s the corrected version of your code:

= Table.ReplaceValue(
    #"Clean data Name",
    each [#"Volume(24h)"],
    each Text.RemoveRange([#"Volume(24h)"], Text.Length([#"Volume(24h)"]) - Text.Length([Acronyme]), Text.Length([Acronyme])),
    Replacer.ReplaceText,
    {"Volume(24h)"}
)

This ensures that Power Query correctly identifies the column name and processes it without syntax errors.

 

Best regards,

View solution in original post

3 REPLIES 3
informer
Helper I
Helper I

Thanks a lot DataNinja777 for your so precious response

Best regards

informer
Helper I
Helper I

Hi DataNinja777

 

Thanks a lot fot this simple but so precious information !

DataNinja777
Super User
Super User

Hi @informer ,

 


The issue occurs because column names with special characters, such as parentheses, require special handling in Power Query (M language). In your case, Volume(24h) contains parentheses, so it must be enclosed in square brackets and quoted with a # sign and double quotes. The correct approach is to reference it as #"Volume(24h)" throughout the formula. Here’s the corrected version of your code:

= Table.ReplaceValue(
    #"Clean data Name",
    each [#"Volume(24h)"],
    each Text.RemoveRange([#"Volume(24h)"], Text.Length([#"Volume(24h)"]) - Text.Length([Acronyme]), Text.Length([Acronyme])),
    Replacer.ReplaceText,
    {"Volume(24h)"}
)

This ensures that Power Query correctly identifies the column name and processes it without syntax errors.

 

Best regards,

Helpful resources

Announcements
Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

October Power BI Update Carousel

Power BI Monthly Update - October 2025

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

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.