cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Microsoft
Microsoft

OLE DB or ODBC error: type mismatch (exception from HRESULT: 0x80020005 (DISP_E_TYPEMISMATCH))

Hello,

 

I have a report that has been running just fine for the last few weeks.  Nothing has changed about the report.

 

Upon attempting to refresh the data today - it does not work.  If gives me this error:

 

     OLE DB or ODBC error: type mismatch (exception from HRESULT: 0x80020005 (DISP_E_YTPEMISMATCH))

 

Any ideas about what is going on and how to address this?

 

Thanks,

 

 

22 REPLIES 22
New Member

Hi,

 

Reason for this error is that the content of your data has changed.

It means for example that you have a text in a number formatted column.

For example :

* you have a column in your report who also only containes number values and your data type is also number.

 When refreshing your data if this column now contains a text value, then you will receive this error.(This is the reason for mismatch)

#example;

   row      column a 

      1        10

      2        22

      3        35

      4        Ranking

 

You can solve this with Power Query by sorting and deleting this unwanted rows and your report will refresh again.   

 

 

Helper II
Helper II

Hi, What is your data source?

 

I got this error when I appended the data from CSV and Data from excell.

I'm getting this error from a sharepoint excel. I've formatted all columns in the offending table as text and deleted all relationships..still there. 

Frequent Visitor

I was able to resolve this error, it turns out that when I was merging 2 Excel tables with same columns, the columns themselves didn't get the correct matching types.   Once I changed the columns to match it worked properly.

Frequent Visitor

Hi,

 

had this error a couple of times...was able to solve it everytime when I checked the source. In the last case my Excel table (which I feed manualy) produced a few empty rows at the end refering to no data...deleted them and everything was fine.

Super User IV
Super User IV

Is this in the Service, Desktop or gateway?


---------------------------------------

@ me in replies or I'll lose your thread!!!

I have a NEW book! 
DAX Cookbook from Packt
Over 120 DAX Recipes!




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Desktop.....

Can you please give us some information about your query and the failure? Sending a frown with traces would be very helpful.

 

(Just a guess, are you connecting to an Analysis Services Database?)

Yes, frown with data has now been sent.

 

Sources are Sharepoint List and OData....

I'm seeing exactly the same error. Report was running fine? Using Power BI desktop and source is a SQL server database.

 

Sorry to hear that.  You could open a ticket, but here are a few suggestions.

 

Run the refresh in PowerBI.com - it will fail, but the error reporting is better (? why ? I don't know) - so if you look at the dataset in the "schedule refresh" area, you will see the failure notification -  if you expand that, it may identify the column that is causing the problem.  Then you step through your query (and rebuild it if necessary).

 

If that error does not show, go to PowerBI desktop and get into the data view - then look at the fields list and start by inspecting any columns that are flagged, then look for items that are have date format. Hypotheis is that a new value showed up in your data that caused PowerBI to "change it's mind" about the TYPE - moving from Text or Date Type to "any" or "text". 

 

May need to rebuild those. 

 

I do not think this was a matter of someone changing the format in the source - so the cause of the problem is not known - one day it was working, the next it was not - so I would not advise going down that path as a first step - unless you control everything and have easy access.

 

Good luck.

 

 

 

 

Just had the same error and solved it by duplicating my table in the Query Editor, deleting the original table and renaming the copy to the original's name.. Hope that helps

This works for me, thanks!

Thank you very much.

It did not help. I lost my charts in the process because they were built on the original.

It didn´t help. I just lost all my charts and need to start building from scratch! Smiley Sad

Frequent Visitor

It worked thank you very much!

 

Too bad I had to copy all my old measures again and change the origin of the dependant queries, but it helped a lot 🙂

 

A date field was giving me probs, it loaded from SQL as text, so I changed it to Decimal number and then then tried to create a Date field, But I still got that message, so I left it as a Decimal number and created  four seperate columns, Year, Month, Day and then concateated them together and the query reloads without the error.  Hope that helps someone.

Frequent Visitor

It worked, thank you very much...only problem is that I lost all the measures I inserted in that table 😞
Now I'm copying the formulas from my older .pbix, but this is really problematic, I hope this gets fixed soon by PBI Team, considering that in June 2018 is still happening.

 

Thank you again chabib 🙂

Helpful resources

Announcements
secondImage

Congratulations!

We are excited to announce the Power BI Super Users!

Microsoft Ignite

Microsoft Ignite with Arun Ulag

Featured Session: Drive Data Culture with Power BI- Vision, Strategy & Roadmap. Register here https://myignite.microsoft.com #MSIgnite #PowerPlatform #Power BI ​

Microsoft Ignite

Microsoft Ignite

Join digitally, March 2–4, 2021 to explore new tech that's ready to implement. Experience the keynote in mixed reality through AltspaceVR!

secondImage

The largest Power BI virtual conference

100+ sessions, 100+ speakers, Product managers, MVPs, and experts. All about Power BI. Attend online or watch the recordings.

Top Solution Authors
Top Kudoed Authors