A collection of the issues I run into day to day using the Query Editor along with the magic sauce to make it better
email@example.com wrote this almost 7 years ago and it was last updated over 3 years ago.
I've been using the Query Editor for Power Query and Power BI since around early 2015. In this same time I've been learning Web Development with Ruby on Rails and more gneralised Programming using Ruby and Node.js. This has given me some great insight into how development should be done to achieve maximum productivity and minimise risk.
I won't go into the major items that are missing such as:
Below (with some kind of rank of annoyance) are some simple tweaks that I think can be made to the Query Editor to give me a productivity boost:
Disclaimer: I know this is just a list of vscode features... so the sooner they bake vscode as the editor the better. We don't need another 20 years in the hole of VBA IDE.
Power Query by default, names your query steps using natural language like
Filter by Customer. But in the background, it is creating that step as `#"Filter by Customer"
If you use snake_case as your variable names, it becomes a pain to select the entire variable name when double clicking. Only the word gets selected, whereas, in most editors, it will select the entire string including the underscore _ and other strings connected by that underscore.
My workaround for this is to use
camelCase or just
PascalCase for each variable. My preference is
PascalCase as this follows the naming convention of the Power Query M functions ie
Table.AddColumn ... but you should just use something without spaces or underscores.
I would love to just abolish the whole natural language
#"" thing and replace everything with
PascalCase ... or my real preference of
snake_case. That way I resolve some of these other issues.
I know that
vscode is being integrated as the editor for Power BI and that someday this might hit general available (GA) and make its way to the Power Query Editor. Until then, even having the
Ctrl+D multi selection feature that most modern editors has would be a huge productivity boost. Right now, I end up copy/pasting to vscode to make the edit and then copy/paste back.
This one is hard to explain. I'll try and gif it.
Do I need to even explain this. We get a huge dump of code (refer to the 'Prettify the Code' issue) and then are expected to eyeball the code to find that one line that we are looking for.
When using GUI buttons to make transformations (ie what most people do rather than free type Power Query M into the editor) it should be formatted prettier. Things like indentation, multiple rows per line of code, just the usual stuff we do rather than dumping everything on one line in the editor.
I just want indentation by default to be 2 spaces... it keeps things easy to read. I am not saying everyone should do this. I just want to be able to set option.