Facets
So far, we have looked at the base data types in the M language, both the primitive and the custom ones. However, you may have encountered values that look like data types, but with a different notation. For instance, when selecting a new data type, you see the following popup:
Figure 5.32: The drop-down menu for changing column types
Notice how the menu shows four different ways to label number values. Now, suppose we change a column to Decimal Number and a column to a Fixed decimal number. The UI produces the following code:
Table.TransformColumnTypes( Source ,
{ { "Name", type number },
{ "Value", Currency.Type } } )
The first type transformation references the familiar type number. However, what exactly is Currency.Type
? The answer is this is one of the Type Facets, commonly referred to as facets.
Type Facets provide additional information about your data types. They become useful when Power Query needs to talk to other...