Share via

Missing Coalesce function in Excel Power Pivot

Brian Koo 0 Reputation points
2025-07-18T15:54:38.87+00:00

I am trying to use Coalesce in a Measure in Power Pivot. It gives me this error:

"Failed to resolve name 'COALESCE'. It is not a valid table, variable, or function name."

I am using Office 365 for Enterprise, I have checked that my DAX engine is the latest, I am using other excel files as data sources. Testing code "=Coalesce(0,0)" gives me the same error.

What is wrong?

Microsoft 365 and Office | Excel | For business | Windows
0 comments No comments

2 answers

Sort by: Most helpful
  1. Ashish Mathur 85 Reputation points
    2025-07-18T22:54:15.3766667+00:00

    Hi,

    That DAX function works in PowerBI Desktop (not in PowerPivot). Try this alternative calculated column formula in PowerPivot

    Column = if(isblank(Data[Column1]),Data[Column2],Data[Column1])

    Hope this helps.

    Was this answer helpful?

    1 person found this answer helpful.
    0 comments No comments

  2. Chris Duong 8,740 Reputation points Microsoft External Staff Moderator
    2025-07-18T16:30:22.8433333+00:00

    Hi Brian Koo

     

    Thank you for posting your question in the Microsoft Q&A forum.  

     

    Based on your description and current setup (Office 365 for Enterprise, latest DAX engine, Excel files as data sources), the error message: 

    “Failed to resolve name 'COALESCE'. It is not a valid table, variable, or function name.” 

    suggests that the COALESCE function is not recognized in your Power Pivot environment. Here's a breakdown of why this might be happening and what you can do: 

    1. Function Availability: While COALESCE is a valid DAX function in Power BI and some versions of Analysis Services, it is not yet supported in Excel Power Pivot, even in the latest Office 365 builds. 
    2. Excel DAX Limitations: Excel’s DAX engine lags behind Power BI in terms of function support. Many newer DAX functions (like COALESCE, REMOVEFILTERS, SELECTEDVALUE) are not available in Power Pivot. 

     

    I'd suggest trying the following steps: 

    • You can replicate COALESCE behavior using nested IF or IFERROR statements. For example: 

     

    =IF(NOT(ISBLANK([Value1])), [Value1], IF(NOT(ISBLANK([Value2])), [Value2], 0))  

    • Or, for simpler cases: 

    =IFERROR([Value1], [Value2])  

    These expressions mimic COALESCE by returning the first non-blank or non-error value.

     

    Recommendation 

    If your workflow depends heavily on newer DAX functions, consider using Power BI Desktop, which supports the full DAX language including COALESCE. 

    For detailed guidance, refer to Microsoft’s official documentation:  

    Note: Microsoft is providing this information as a convenience to you. The sites are not controlled by Microsoft. Microsoft cannot make any representations regarding the quality, safety, or suitability of any software or information found there. Please make sure that you completely understand the risk before retrieving any suggestions from the above link 

     

    If you require more in-depth guidance or support for these steps, you may also contact Microsoft’s higher-level technical support through:        

    Our specialized support team will assist you step by step and ensure you get the most appropriate solution for your needs.   

    Please let us know if you need further clarification or assistance. I really appreciate your patience and look forward to assisting you further.  

    We hope you have a great day!  

     


    If the answer is helpful, please click "Accept Answer" and kindly upvote it. If you have extra questions about this answer, please click "Comment".  

    Note: Please follow the steps in our documentation to enable e-mail notifications if you want to receive the related email notification for this thread. 

    User's image

    Was this answer helpful?


Your answer

Answers can be marked as 'Accepted' by the question author and 'Recommended' by moderators, which helps users know the answer solved the author's problem.