Delve into Value Functions in Power Query M Language, useful when performing operations on values. This page provides a comprehensive list and descriptions of Value Functions available in the M Language.
Delve into Value Functions in Power Query M Language, useful when performing operations on values. This page provides a comprehensive list and descriptions of Value Functions available in the M Language.
Evaluation and Conversion
Function | Description | Input | Output |
---|---|---|---|
Value.Expression | Returns an abstract syntax tree (AST) that represents the value’s expression. | Any | Record |
Value.FromText | Creates a strongly typed value from a textual representation. | Any | Any |
Value.NativeQuery | Evaluates a query against a target. | Any | Any |
Value.Optimize | Signals Value.Expression to return the optimized expression for a value. | Any | Any |
Type and Metadata
Function | Description | Input | Output |
---|---|---|---|
Value.As | Returns the value if it is compatible with the specified type. | Any | Any |
Value.Is | Determines whether a value is compatible with the specified type. | Any | Logical |
Value.Metadata | Returns a record containing the input’s metadata. | Any | Any |
Value.RemoveMetadata | Strips the input of metadata. | Any | Any |
Value.ReplaceMetadata | Replaces the input’s metadata information. | Any | Any |
Value.ReplaceType | Replaces the value’s type. | Any | Any |
Value Comparison
Function | Description | Input | Output |
---|---|---|---|
Value.Compare | Returns -1, 0, or 1 based on whether the first value is less than, equal to, or greater than the second. | Any | Number |
Value.Equals | Returns whether two values are equal. | Any | Logical |
Value.NullableEquals | Returns whether two values are equal. | Any | Logical |
Value Operations
Function | Description | Input | Output |
---|---|---|---|
Value.Add | Returns the sum of the two values. | Any | Any |
Value.Divide | Returns the result of dividing the first value by the second. | Any | Any |
Value.Multiply | Returns the product of the two values. | Any | Any |
Value.Subtract | Returns the difference of the two values. | Any | Any |
Other Functions
Function | Description | Input | Output |
---|---|---|---|
Action.WithErrorContext | This function is intended for internal use only. | Any | Any |
DirectQueryCapabilities.From | This function is intended for internal use only. | Any | Table |
Embedded.Value | Accesses a value by name in an embedded mashup. | Any | Any |
Excel.ShapeTable | This function is intended for internal use only. | Table | Any |
Graph.Nodes | This function is intended for internal use only. | Record | List |
Progress.DataSourceProgress | This function is intended for internal use only. | Any | Any |
SqlExpression.SchemaFrom | This function is intended for internal use only. | Any | Any |
SqlExpression.ToExpression | Converts the provided SQL query to M code | Text | Text |
Value.Alternates | Expresses alternate query plans. | List | Any |
Value.Firewall | This function is intended for internal use only. | Text | Any |
Value.Lineage | This function is intended for internal use only. | Any | Any |
Value.Traits | This function is intended for internal use only. | Any | Table |
Value.Type | Returns the type of the given value. | Any | Type |
Value.VersionIdentity | Returns the version identity of the value, or null if it doesn’t have a version. | Any | Any |
Value.Versions | Returns a navigation table containing the available versions of value. | Any | Table |
Value.ViewError | This function is intended for internal use only. | Record | Record |
Value.ViewFunction | This function is intended for internal use only. | Function | Function |
Variable.Value | This function is intended for internal use only. | Text | Any |
