Forum Discussion
deleted columns in excel source
Hi,
I use Power BI Desktop with an excel file as source. I had to delete one column in the excel table and now Power BI always give me an expression.error to tell me that it doesn't find the column.
I already refresh the query editor and delete the column in the pbi desktop, but the error message still come back.
Is there anybody to help me ?
Thanks !
You have to delete the specified column from all the steps in Query editor. Let's have a look into Advanced editor in Home ribbon and delete all parts of code where the specified column is used - not the steps but only the sections connected to the column.
That's it.
Regards.
Pavel
6 Replies
- PavelRSolution Specialist
You have to delete the specified column from all the steps in Query editor. Let's have a look into Advanced editor in Home ribbon and delete all parts of code where the specified column is used - not the steps but only the sections connected to the column.
That's it.
Regards.
Pavel
- john0305New Member
Thank you, I've been having this problem as well. The company that generates my report decided it would be fun to change the column names ever so slightly which ruined my report.
I followed the steps you listed and I think I finally have an updated report. These are the steps I did (the ones you listed but also additional)
I went into the data tab and right clicked on the report in the right section labeled fields and click edit query.
I clicked on Advanced Editor and copy and pasted it into word (for finding/editing purposes). Removed the section that was causing problems starting from the comma to the next comma ensuring I left one between sections.
Then copied and pasted back into BI, hit done and waited for the next error.... rinse and repeat until you no longer get errors.
Then I clicked on the gear for "Source" in the applied steps section
Changed Open file as to "Automatic"
Doubled Clicked on the file shown
Clicked Insert
Then hit close and apply.
I now had a refreshed updated report... Annoying (I hope there is an easier way someone can describe) but it worked so now future reports will just update with no issues.
Oh and if you have a report you made it may have a button called Fix, I had to do that at least once.
- john0305New Member
Thank you, I've been having this problem as well. The company that generates my report decided it would be fun to change the column names ever so slightly which ruined my report.
I followed the steps you listed and I think I finally have an updated report. These are the steps I did (the ones you listed but also additional)
I went into the data tab and right clicked on the report in the right section labeled fields and click edit query.
I clicked on Advanced Editor and copy and pasted it into word (for finding/editing purposes). Removed the section that was causing problems starting from the comma to the next comma ensuring I left one between sections.
Then copied and pasted back into BI, hit done and waited for the next error.... rinse and repeat until you no longer get errors.
Then I clicked on the gear for "Source" in the applied steps section
Changed Open file as to "Automatic"
Doubled Clicked on the file shown
Clicked Insert
Then hit close and apply.
I now had a refreshed updated report... Annoying (I hope there is an easier way someone can describe) but it worked so now future reports will just update with no issues.
Oh and if you have a report you made it may have a button called Fix, I had to do that at least once.
- titou64New Member
Thanks for your help ! It works ! :smileyhappy: