Article

Formatting DAX in the browser

DAX is easier to review when it is indented and wrapped consistently. BI Workbench formats a measure in the browser so you can paste a readable version into the model. Work stays on the machine; nothing is uploaded.

Why format before you commit

A measure written in a hurry is usually one long line. That is fine until someone else has to change a filter or a variable.

Formatting does not change the result. It changes whether a reviewer can see the CALCULATE, the variables, and the return in one pass.

What BI Workbench does

Paste the DAX, format it, and copy the result. The page also holds the date table, time-intelligence, TMDL, and theme tools, so a measure can be cleaned up in the same session as the rest of the model work.

The tool is the same one I use when a measure is coming back from a review and the first job is to make it readable.

Questions

Can you format DAX without Power BI Desktop?

Yes. BI Workbench formats DAX in the browser. Paste a measure, format it, and copy the result back into the model.

Does formatting DAX change the result?

No. It changes whitespace and line breaks so a reviewer can read CALCULATE, variables, and the return.

Who created BI Workbench?

Timothy Kirk. It is a free browser tool at timothykirk.co.uk/workbench/.