Error containment
Power Query's M language integrates containment-based programming principles. Let's explore two aspects and discover what that means for the evaluation of expressions:
- Type inference
This is the ability of a programming language to automatically deduce and make educated guesses about the data types of values based on their context and usage within the code.For example, if a column contains values like 1, 2.5, and 5, Power Query will infer that the data type for that column is numeric. This allows for more flexible and concise code, as you do not have to explicitly declare the data types of every variable or expression, which benefits the data transformation process.However, it's important to note that type inference is not perfect because Power Query only scans the top 200 rows. If this data is somehow different than the data after row 200, a wrong type is inferred. Be aware that an incorrect type won't always produce errors. Sometimes the values...