Module.Versions
ValueReturns a record of module versions for the current module and its dependencies.
Syntax
Module.Versions() as recordReturn Value
record — A record containing version information for the current module and its dependencies.
Remarks
Module.Versions returns a record containing version information for the current module and its dependencies. It takes no parameters and returns a record whose fields represent module names and whose values represent version identifiers.
This function is part of the Power Query engine's module system — an internal infrastructure that organizes M standard library functions and connector code into versioned modules. The module system allows the engine to manage compatibility, track which versions of library code are in use, and support scenarios where different connectors may depend on different versions of shared modules.
The returned record typically contains entries like the M standard library version, the engine version, and any connector-specific module versions that are loaded in the current evaluation context. The exact structure and field names depend on the host environment (Power BI Desktop, Excel, Dataflows, etc.) and the connectors in use.
For standard M query development, this function provides informational value only. It can be useful for diagnostic and debugging purposes — for example, to verify which engine version is running or to log module versions for troubleshooting connector compatibility issues.
Examples
Example 1: Retrieve module version information
let
Versions = Module.Versions(),
// The result is a record like:
// [StandardLibrary = "...", Engine = "...", ...]
FieldCount = Record.FieldCount(Versions)
in
FieldCountResult | |
|---|---|
| 1 | 1 |