Check your eligibility for this 50% exam voucher offer and join us for free live learning sessions to get prepared for Exam DP-700.
Get StartedDon't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.
hello all,
Can yo please explain logic of error.
Measure is:
Solved! Go to Solution.
HI @answeriver ,
Your syntax error is somehwere in this part of DAX:
ALLEXCEPT(
REPORT_IMS, 'REPORT_IMS'[CITY], REPORT_IMS[REGION (groups)], REPORT_IMS[VISIT MONTH]
), // you have closed the ALLEXCEPT clause here
REPORT_IMS[VISIT YEAR],'Attributes','Attributes'[type contract] // this is the line with error I guess
Question for you: What you are trying to achieve here with the line of code above?
You will have to correct your DAX something like this:
= CALCULATE(
DISTINCTCOUNT(REPORT_IMS[SALEPOINT CODE])
)
/
CALCULATE(
DISTINCTCOUNT(REPORT_IMS[SALEPOINT CODE]),
ALLEXCEPT(
REPORT_IMS, 'REPORT_IMS'[CITY], REPORT_IMS[REGION (groups)],
REPORT_IMS[VISIT MONTH], REPORT_IMS[VISIT YEAR]
),
ALLEXCEPT(
'Attributes','Attributes'[type contract]
)
)
Check if the above DAX works. Make sure to write your DAX as clean as possible - specially the closing and opening brackets.
HI @answeriver ,
Please create a new thread for this if this is something different to the syntax error issue that you raised.
HI @answeriver ,
Your syntax error is somehwere in this part of DAX:
ALLEXCEPT(
REPORT_IMS, 'REPORT_IMS'[CITY], REPORT_IMS[REGION (groups)], REPORT_IMS[VISIT MONTH]
), // you have closed the ALLEXCEPT clause here
REPORT_IMS[VISIT YEAR],'Attributes','Attributes'[type contract] // this is the line with error I guess
Question for you: What you are trying to achieve here with the line of code above?
You will have to correct your DAX something like this:
= CALCULATE(
DISTINCTCOUNT(REPORT_IMS[SALEPOINT CODE])
)
/
CALCULATE(
DISTINCTCOUNT(REPORT_IMS[SALEPOINT CODE]),
ALLEXCEPT(
REPORT_IMS, 'REPORT_IMS'[CITY], REPORT_IMS[REGION (groups)],
REPORT_IMS[VISIT MONTH], REPORT_IMS[VISIT YEAR]
),
ALLEXCEPT(
'Attributes','Attributes'[type contract]
)
)
Check if the above DAX works. Make sure to write your DAX as clean as possible - specially the closing and opening brackets.
Thank you Pragati11.
My fault with ). Actualy i need to count count of salepoint code devide on total salepoint cod with filters ALLEXCEPT. Measure from you is working without errors, but filter "type contract" whatever don't showing needs results.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Prices go up Feb. 11th.
Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.
User | Count |
---|---|
147 | |
85 | |
66 | |
52 | |
46 |
User | Count |
---|---|
215 | |
90 | |
83 | |
66 | |
58 |