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

Join us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.

Reply
username100
New Member

Error in PQ - Expression.SyntaxError: Token ')' expected

hi everyone , new to PQ in powerBI , i keep on getting this error , Expression.SyntaxError: Token ')' expected

 

this is my custom column - = Table.TransformColumns(#"Grouped Rows",("First Transaction Month",Date.StartOfMonth,Date.Type)

 

would appreciate any insights on this, as I am stuck here, I am doing a sample customer cohort & retention analysis 

2 ACCEPTED SOLUTIONS
ZhangKun
Super User
Super User

Table.TransformColumns(#"Grouped Rows",{"First Transaction Month", Date.StartOfMonth,Date.Type})

or 

Table.TransformColumns(#"Grouped Rows",{{"First Transaction Month", Date.StartOfMonth,Date.Type}})

 

For a single conversion, you can use either {} or {{}}

View solution in original post

Omid_Motamedise
Super User
Super User

Hi, it is all about the second argument, you should provide it in a list. IF you are going to transform values on a column, you just need to use one List sign, but to change the values on more than a column, you have to provided a list including one sub list for each column, so revise your formula to=>


Transform a column = Table.TransformColumns(#"Grouped Rows",{"First Transaction Month",Date.StartOfMonth,Date.Type})


Transform two column= Table.TransformColumns(#"Grouped Rows",{{"First Transaction Month",Date.StartOfMonth,Date.Type},{"Name column 2}, each _+1})

If my answer helped solve your issue, please consider marking it as the accepted solution. It helps others in the community find answers faster—and keeps the community growing stronger!
You can also check out my YouTube channel for tutorials, tips, and real-world solutions in Power Query with the following link
https://youtube.com/@omidbi?si=96Bo-ZsSwOx0Z36h

View solution in original post

7 REPLIES 7
v-mdharahman
Community Support
Community Support

Hi @username100,

May I ask if you have resolved this issue? If so, please mark the helpful reply and accept it as the solution. This will be helpful for other community members who have similar problems to solve it faster.

 

Thank you.

v-mdharahman
Community Support
Community Support

Hi @username100,

I wanted to check if you had the opportunity to review the information provided. Please feel free to contact us if you have any further questions. If my response has addressed your query, please accept it as a solution and give a 'Kudos' so other members can easily find it.

Thank you.

v-mdharahman
Community Support
Community Support

Hi @username100,

As we haven’t heard back from you, so just following up to our previous message. I'd like to confirm if you've successfully resolved this issue or if you need further help?

If yes, you are welcome to share your workaround and mark it as a solution so that other users can benefit as well. If you find a reply particularly helpful to you, you can also mark it as a solution.


If you still have any questions or need more support, please feel free to let us know. We are more than happy to continue to help you.
Thank you for your patience and look forward to hearing from you.

v-mdharahman
Community Support
Community Support

Hi @username100,

Thanks for reaching out to the Microsoft fabric community forum.

 

It looks like you are facing an issue with syntax when you are creating a new custom column. As @Omid_Motamedise @ZhangKun and @Anonymous provided you with solutions from their side, Please do Mark them as solution if it solves your problem.

 

If I misunderstand your needs or you still have problems on it, please feel free to let us know.  

Best Regards,
Hammad.
Community Support Team.

 

If this post helps then please mark it as a solution, so that other members find it more quickly.

Thank you.

Omid_Motamedise
Super User
Super User

Hi, it is all about the second argument, you should provide it in a list. IF you are going to transform values on a column, you just need to use one List sign, but to change the values on more than a column, you have to provided a list including one sub list for each column, so revise your formula to=>


Transform a column = Table.TransformColumns(#"Grouped Rows",{"First Transaction Month",Date.StartOfMonth,Date.Type})


Transform two column= Table.TransformColumns(#"Grouped Rows",{{"First Transaction Month",Date.StartOfMonth,Date.Type},{"Name column 2}, each _+1})

If my answer helped solve your issue, please consider marking it as the accepted solution. It helps others in the community find answers faster—and keeps the community growing stronger!
You can also check out my YouTube channel for tutorials, tips, and real-world solutions in Power Query with the following link
https://youtube.com/@omidbi?si=96Bo-ZsSwOx0Z36h
ZhangKun
Super User
Super User

Table.TransformColumns(#"Grouped Rows",{"First Transaction Month", Date.StartOfMonth,Date.Type})

or 

Table.TransformColumns(#"Grouped Rows",{{"First Transaction Month", Date.StartOfMonth,Date.Type}})

 

For a single conversion, you can use either {} or {{}}

Anonymous
Not applicable

Try

 

able.TransformColumns(#"Grouped Rows",{{"First Transaction Month",Date.StartOfMonth, type date}})

 

--Nate

Helpful resources

Announcements
July PBI25 Carousel

Power BI Monthly Update - July 2025

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

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 community update carousel

Fabric Community Update - June 2025

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