Visual Studio Code

Visual Studio Code is a free, lightweight code-editing tool from Microsoft that's available on all platforms (Windows, Mac, Linux). Power Query M Language is an extension to Visual Studio Code that provides code-editing support for M queries, as shown in the following screenshot:

M Query in Visual Studio Code

In this example, the same Internet Sales query viewed in the Advanced Editor of Power BI Desktop has been copied into a Visual Studio code file and saved with a (.pq) file extension. Once saved in a supported file extension, code-editing features, such as colorization, auto-closing, and surrounding detection, are applied. M query files can be opened and saved with the following four file extensions—.m, .M, .pq, and .PQ.

Since the .pq file extension is used by the Power Query SDK for Visual Studio, as described in the following section, this file extension is recommended for storing M queries.

In the initial release of the extension (v 1.0.0), IntelliSense is limited to the terms within the query. Future updates will likely include IntelliSense support for the standard library of M functions and common M syntax, similar to the Power Query SDK for Visual Studio. To install the Power Query M Language extension for Visual Studio Code, open the Extensions Marketplace in Visual Studio Code (View | Extensions) and search for the name of the extension.

Prior to the M extension for Visual Studio Code and the Power Query SDK for Visual Studio, M developers commonly utilized the free Notepad++ code editor application. Since M is not a standard supported language for this tool, developers would create a user-defined language by pasting or typing in a list of M functions and keywords. The following blog post from Lars Schreiber, MS MVP, walks through the M for Notepad++ setup process: http://ssbi-blog.de/technical-topics-english/power-query-editor-using-notepad/.
..................Content has been hidden....................

You can't read the all page of ebook, please click here login for view all page.
Reset
18.225.254.192