Tabular editor as a nice tool. It can find some troubles in data model and sometimes even fix them.

We are not talking about obvious errors (like syntax). It´s more about troubles related to low performance or poor readability of model.

How to start?
Let´s have your Tabular Editor connected to Power BI Desktop.

In Advanced Scripting Window run this code:

  • System.Net.WebClient w = new System.Net.WebClient();
    string userName = System.Environment.UserName;
    string url = “https://raw.githubusercontent.com/microsoft/Analysis-Services/master/BestPracticeRules/BPARules.json”;
    string downloadLoc = @”C:\Users\”+userName+@”\AppData\Local\TabularEditor\BPARules.json”;
    w.DownloadFile(url, downloadLoc);

Automatical checking and improving of Data Model with Tabular Editor

Then close and reopen Tabular Editor.

In Tabular Editor press F10 (or go to Tools / Best Practice Analyzer).

See the result:

Automatical checking and improving of Data Model with Tabular Editor

It shows parts of model, that don´t comply with Microsoft best practices. In some of them, you can simply use right button and solve it.

The fix is written back to Power BI Desktop file.

Automatical checking and improving of Data Model with Tabular Editor