Will make this short and sweet - we have a massive .CSV that we are linking to PBI Desktop. Some of the header names in this .CSV were not optimal and have since been updated by the SQL backend. However, PBI is not happy with not being able to find the exact header that existed previously, and we could not find a route by which to tell the software that a header name had changed. Is there a quick solution for this?
Here is an idea to work around this issue,
as long as your header are changing, I recommend you to do these step in power query:
search on your power query the step where the headers are promoted
instead of this step, delete the first row (the one containing the headers)
Then add a step renaming the header as desired
Hope that helps
Quick.. Not so much. Easy? Relatively.
You'll need to manually edit the PowerQuery in the Advanced Query side.
I recommend un-hiding the formula bar in the Query Editor and going step by step through the applied steps. Once you find a broken step, check out the PowerQuery, you'll see your no longer existent fields there as plain text in the formula bar ( or advanced editor view ). Swap out the old field names in the PowerQuery with the new names and you should be golden.
You might even get away with a few find/replaces..
You can fix this if you delete your top rows in your first row operation in query editor. This way the CODE of your power BI query will not contain a specific name and will name your columns: 'column 1' ; 'column 2' etc.etc.
You can now edit to your own demands and when you change datasource nothing will go in error.
Hope this helps for people who are also looking into the problem.
Related
I'm new to PowerBI, and am working on a large database. I am attempting to prepare the data in the PowerQuery Editor.
I would like to code as many steps as possible, as analysing each column manually is extremely time consuming.
My coding goals (in order of priority):
For each query I would like to get their column quality.
Ideally, I would like to export the header names with the column quality, so that I can determine which are relevant. Furthermore, I can also use the column names to determine which column relationships might be relevant. The database is huge, so simply just importing all the data and trying to work with it from their is not feasible, in fact PowerBI comes up with the error that I don't have enough free memory.
I have VBA and some SQL experience.
I know I have a lot to learn w.r.t. PowerBI, and I am working on it, but need some guidance and direction, also on what is possible/feasible.
Any contructive hints, advice, or feedback would be appreciated - thank you!
Use Table.Profile() on each table and load to the data model.
https://learn.microsoft.com/en-us/powerquery-m/table-profile
I have a column with lengthy values in my Power BI table. I would like it to only show a part of it so that the table isn't hard to navigate, and once the viewer clicks or do something, then it shows the whole value. Is there a way I can accomplish this?
There are posts about collapsing/expanding the whole column, as in keep it disappeared and then appear once you expand or vice versa, but I can't find a way to collapse/expand each values.
Following is an example. As you can see, "Bio" column is very lengthy, so I would it to show maybe a few lines in original view, and once the viewer wants to see the full Bio of that authors, then they can by a click or any action.
Any help would be much appreciated!
OriginalTable
What I want
You can add a column with the truncated version, and a Drill Through to a report page for that single bio.
I have a number of very wide datasets in Power Query - hundreds of columns each (don't ask). I am trying to determine if (how) to assign columns to display folders programatically. I have access to some data that I could use to assign the display folder based on the column name. Some research into the metadata functions in M is tantalizing but I have not found the silver bullet example yet. Has anyone attempted this?
I've done some basic research and written some bits of M to look at the metadata functions, but that's about it. I was hoping someone might have the magic function call needed to set the display folder, or know if it is even possible.
I have multiple Excel files in one folder and I loaded the entire folder to PowerBI. The first Excel file is the sample file to PowerBI and I applied some formatting steps to this table of which one of those is to remove the top three rows. PowerBI should now remove the three top rows of all other Excel files in this folder too now. However, I see that of some Excel files it only removes 1 row. Does anybody know what causes this? Thanks in advance.
This is probably caused by inconsistent Excel files. The most common issue that would cause the behavior you describe is hidden rows in Excel, which Power BI will read as data rows. But hey - it's Excel so the users could've done almost anything.
You can edit the Sample File query to point it at the file with issues which might give you more insight.
More generally I would say that is a fragile query design, instead I would try to filter on a column e.g. Remove Empty.
It was caused by the fact that the merging of all Excel files happens before the Top 3 Rows were removed, resulting in the fact that only the first three rows of the total merged table were removed.
enter image description here
I want to add filter on each column like Excel filter. I already researched all solution but not find any good way.
I think this should work without knowing what any of your data or setup looks like.
In the Query editor, go to the Transform tab. Use First Row as
Headers.
Select the column that you'd like to and make sure to unpivot any
columns associated.
Rename the columns ( if necessary )
Close and Apply.
If you provide a some additional detail on the data, how it's currently configured, etc. I think it would make it easier to help.