Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 

Earn a 50% discount on the DP-600 certification exam by completing the Fabric 30 Days to Learn It challenge.

Reply
FireFighter1017
Advocate II
Advocate II

If Power Query M advanced editor would be actually advanced

Hi,

 

It would be really nice if Power Query M advanced editors from both Power BI Service Dataflows, Power BI Desktop and Excel would be an actual "advanced" editor with code formatting features and in sync when it comes to automatically naming the steps.

'Cos currently, sometimes it will use a capitalized letter for the second word, sometimes not, sometimes calling it "Changed column type" other times "Transformed column".

 

And the code indentation...  It's kind of a mess even within a single one of those editors.

 

I have noticed that the indentation in Power Query Advanced editor is inconsistent.

Sometimes it will use 2 spaces, sometimes 4.

I mean, I don't care that from one query to another the indentation is different.  But it bothers me when I copy/paste steps from one script to another and I end up messing with the indentation having some lines at 4 spaces, some lines at 2 spaces.

 

Is there anything I can do to set the indentation to 2 spaces by default and have the editor enforce this rule for me?

I mean, I'm not even the one setting the indentation.  It seems to recognize the number of indentation and then set the tab to this number of spaces.

Like in this example, the tab is set to 2 spaces as we can see with the guide lines:

FireFighter1017_0-1695305011894.png

 

And then, in the same Dataflow, I have this other query where the tab is clearly set to 4 spaces:

FireFighter1017_1-1695305095268.png

And unless I copy/paste this code into VSCode for example and have the tab set to 2 spaces and copy it back, or I manually set the indentation to 2 spaces on every single line, there is no way or me to set the tab space to 2 instead of 4.

So I ended up using 4 spaces which I find impractical because it takes a lot of space in the screen and the Power Query advanced editor is not really advanced in terms of IDE.

 

4 REPLIES 4
collinq
Super User
Super User

Hi @FireFighter1017 ,

 

I do not believe that there are any "format" functionality at all (I would like things like "search" in it as well)!  Maybe you can add this to "Ideas".  If you do, please let us know and we can vote for it as well.

 




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

Proud to be a Datanaut!
Private message me for consulting or training needs.




I did just what you suggested.  Here's the idea request: Power Query Advanced Editor be an actual 'advanced... - Microsoft Fabric Community

Voted!




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

Proud to be a Datanaut!
Private message me for consulting or training needs.




Greg_Deckler
Super User
Super User

@FireFighter1017 Not much that can be done. The Advanced Editor is a misnomer. Should just be Code Editor.


@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
The Definitive Guide to Power Query (M)

DAX is easy, CALCULATE makes DAX hard...

Helpful resources

Announcements
LearnSurvey

Fabric certifications survey

Certification feedback opportunity for the community.

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

Check out the April 2024 Power BI update to learn about new features.

April Fabric Community Update

Fabric Community Update - April 2024

Find out what's new and trending in the Fabric Community.

Top Solution Authors
Top Kudoed Authors