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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
kelly008
Helper I
Helper I

Syntax For ')' Error Message

Hello,

 

I am currently getting this error message: 

 

kelly008_0-1668605576244.png

Text version:   The syntax for ')' is incorrect. (DAX(VAR OverallStartDate = [OverallStartDate]VAR StartDate = CALCULATE( MIN(Project[Starting_Date]), REMOVEFILTERS(dimDate) )VAR Result = INT(StartDate - OverallStartDate)RETURN)).

 

For this Measure:

 

kelly008_1-1668605594033.png

I'm using this measure for the creation of a Gaant Chart Project Scheduler. 

 

Any help would be greatly appreciated.

Thanks!

1 ACCEPTED SOLUTION
DimaMD
Solution Sage
Solution Sage

@kelly008  try it

VAR OverallStartDate = [OverallStartDate]
VAR StartDate = 
CALCULATE( 
MIN(Project[Starting_Date]), 
REMOVEFILTERS(dimDate) 
)
VAR Result = INT(StartDate - OverallStartDate)
RETURN
Result

 


__________________________________________

Thank you for your like and decision

__________________________________________

Greetings from Ukraine

To help me grow PayPal: embirddima@gmail.com

View solution in original post

3 REPLIES 3
DimaMD
Solution Sage
Solution Sage

@kelly008  try it

VAR OverallStartDate = [OverallStartDate]
VAR StartDate = 
CALCULATE( 
MIN(Project[Starting_Date]), 
REMOVEFILTERS(dimDate) 
)
VAR Result = INT(StartDate - OverallStartDate)
RETURN
Result

 


__________________________________________

Thank you for your like and decision

__________________________________________

Greetings from Ukraine

To help me grow PayPal: embirddima@gmail.com

Amazing thank you!!

daXtreme
Solution Sage
Solution Sage

@kelly008 

 

Some highlights:

 

1. Do not name your variables exactly as your measures.

2. The RETURN must return something. Can't be hanging all by itself.

3. Please always format your DAX correctly.

 

If you don't want to format by hand, use www.daxformatter.com. This free tool will also highlight any syntax errors to you.

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

November Power BI Update Carousel

Power BI Monthly Update - November 2025

Check out the November 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.