ErrorIn a TMDL file6 causes · The Report Doctor detects none yet.

TMDL Format Error

Power BI

The message, with the parts that change in brackets:

TMDL Format Error: Parsing error type - [type] Detailed error - [detail] Document - '[file]' Line Number - [n] Line - '[line]'

What it means

Power BI Desktop read a .tmdl file in the project and found something it does not accept. The dialog names the file in Document, the line, and a parsing error type. The type is the best clue to the cause.

Usually
The file starts with a byte order markA property name is misspelledThe Power BI service saved the file in a newer formatA blank line follows a documentation commentA role filter is written as permissionA translation is written as translatedCaption
Fix
Open the file named in Document and go to the line it gives.
On this page

How the message appears

Copied exactly from each source. A name in square brackets replaced one from someone else's project.

There's a problem with the definition content in your Power BI Project.
TMDL Format Error:
	Parsing error type - InvalidLineType
	Detailed error - Unexpected line type: Other!
	Document - './database'
	Line Number - 1
	Line - 'database [model name]'
GitHub issue: TabularEditor/TabularEditor issue 1185. Read 2026-10-03.[1]Identifiers replaced

Read it in this order

  1. Parsing error typeThe clue to the cause. InvalidLineType points to cause 1, the file starts with a byte order mark.
  2. DocumentThe file to open.
  3. Line NumberThe line to go to in that file.
  4. LineThe line as Power BI Desktop read it.
5 more reports of this message
Unable to open file
There's a problem with the definition content in your Power BI Project.
TMDL Format Error:
	Parsing error type - UnknownKeyword
	Detailed error - Unsupported property - formaString is not a supported property in the current context!
	Document - './tables/Product'
	Line Number - 6
	Line - '		formaString: #,##0'
Microsoft Learn: Power BI Desktop project semantic model folder. Read 2026-10-03.[2]Typed from a screenshot
TMDL Format Error:
Parsing error type - UnsupportedObjectType
Detailed error - Unsupported object type - cultureInfo is not a supported property in the current context!
Document - './model'
Line Number - 36
Line - 'ref cultureInfo en-US'
Microsoft forum: Metadata updates in Power BI Service causes issues with GIT integration. Read 2026-10-03.[3]
There's a problem with the definition content in your Power BI Project.
TMDL Format Error:
    Parsing error type - InvalidLineType
    Detailed error - Unexpected line type: Empty!
    Document - './relationships'
    Line Number - 5
...
InnerException0.PowerBINonFatalError_ErrorCode: DataModelLoadFailed
GitHub issue: Kemetra/Seshat-BI issue 494. Read 2026-10-04.[4]
TMDL Format Error:
	Parsing error type - UnsupportedObjectType
	Detailed error - Unsupported object type - permission is not a supported property in the current context!
	Document - './roles/[role name]'
	Line Number - 3
	Line - '	permission [table name] = [region] = LOOKUPVALUE([security table][region],Se'
GitHub issue: alessandrorapitiagic/retail-data-platform-copilot-lab issue 4. Read 2026-10-04.[5]Identifiers replaced
TMDL Format Error: Parsing error type - UnknownKeyword Detailed error - Unsupported property - translatedCaption is not a supported property in the current context! Document - '' Line Number - 10 Line - ' translatedCaption: Ventes'
Desktop run: Power BI Desktop 2.159.883.0, Studio fixture F11. Seen 2026-10-22.[6]

What causes it

  1. The file starts with a byte order mark

    A byte order mark is an invisible character some tools write at the start of a UTF-8 file. Power BI Desktop expects TMDL files without one, and reports InvalidLineType on line 1. The quoted Line starts with it, before database. A Tabular Editor maintainer confirmed this cause and changed its default to save without one.

    Source: TabularEditor/TabularEditor3 issue 1277[7], TabularEditor/TabularEditor issue 1185[1].

    The Report Doctor doesn't detect this yet.
  2. A property name is misspelled

    Microsoft's own example has formaString where TMDL expects formatString. Power BI Desktop reports UnknownKeyword and names the property it does not know.

    Source: Power BI Desktop project semantic model folder[2].

    The Report Doctor doesn't detect this yet.
  3. The Power BI service saved the file in a newer format

    In the quoted case the Power BI service changed culture to cultureInfo in model.tmdl, and Power BI Desktop 2.128 reported UnsupportedObjectType.

    Source: Metadata updates in Power BI Service causes issues with GIT integration[3].

    The Report Doctor can't detect this, because whether a release accepts the file depends on which Power BI Desktop opens it, and the files do not say.
  4. A blank line follows a documentation comment

    A /// comment documents the object under it, so the issue's author says it has to sit directly above that object. In the quoted case a /// block at the top of relationships.tmdl was followed by a blank line. Power BI Desktop reported InvalidLineType with Unexpected line type: Empty! on that blank line. Removing the block let the project open.

    Source: Kemetra/Seshat-BI issue 494[4].

    The Report Doctor doesn't detect this yet.
  5. A role filter is written as permission

    The object that holds a role's filter on a table is tablePermission. In the quoted case two role files used permission, and Power BI Desktop reported UnsupportedObjectType on that line. The issue's author says the fix is to rename it in both files, and points to the example in the Microsoft Learn TMDL overview.

    Source: alessandrorapitiagic/retail-data-platform-copilot-lab issue 4[5].

    The Report Doctor doesn't detect this yet.
  6. A translation is written as translatedCaption

    In a culture, a translated object takes caption, description or displayFolder. Those are the three the Microsoft Learn reference lists, and its pt-PT example uses caption. translatedCaption is not one of them. We wrote it in a script in TMDL view, and Power BI Desktop reported UnknownKeyword on that line. Document - '' means the text came from TMDL view, not from a file.

    Source: Object definitions in Tabular Model Definition Language (TMDL)[8], Power BI Desktop 2.159.883.0, Studio fixture F11[6].

    The Report Doctor doesn't detect this yet.

The fix

Open the file named in Document and go to the line it gives. Correct the property name, or save the file without a byte order mark. If the Power BI service changed the file, undo the change there or put the old name back, as the poster describes with cultureInfo and culture. If the line is a /// comment followed by a blank line, remove the comment or put the object directly under it. If the line starts with permission, rename it tablePermission. If it says translatedCaption, write caption. Which one applies depends on the parsing error type.

In tables/Product.tmdl:

Broken
measure '# Products' = COUNTROWS('Product') * 1
	formaString: #,##0

Line 2: add t.

Fixed
measure '# Products' = COUNTROWS('Product') * 1
	formatString: #,##0

From the SalesSense sample project by Rui Romano (MIT licence).

The Power BI Report Doctor does not find five of these causes yet. It cannot find the sixth, a file the Power BI service saved in a newer format.

Other messages that stop a project opening, by the file that causes each: Power BI Desktop can't open a PBIP.

Worth knowing

  • Most editors show the encoding in the status bar. "UTF-8 with BOM" is the one to change.

Sources

Did this page help?

It tells us which pages to fix first.

What you put into the tools never leaves your browser. We count page views and keep them for 90 days. Accept and we also remember this browser, so a return visit is not counted as new. Privacy policy