


You can sum it, add or subtract a value, calculate averages, round it up or down, and many more things can be done. With number data types, it becomes more interesting because with numbers you can use it for aggregation and extract meaningful information. Text data type is very simple and straight forward. Text (or sometimes referred to as string)īoolean, or logical (also referred to as true/false types)ĭata type is very important, and most often you are required to declare the data type you are working with. There are several types of data, but let's say the most common ones are: So, when used to Excel and its way of handling data, you don't really care about types, but with Power Query, you have to very much care about what type it is. In Excel, adding a number to a date would have worked without any problem.

Your analysis would be affected.Īnd just in case you try to load your data into the data model of Excel.Īnd, actually, when looking at the data model in Power Pivot, well Excel (or Power Pivot, who knows.) got rid of your errors.įurthermore, data type errors are common, and you will often find an error message similar to this one So, you get to know about data types.Īnd because you don't want to end up with errors like this in your data set. Well, because you want control over your data, yep, total control. So, ok, in Excel we didn't really care about types, and Power Query takes care about it (in its own way), so, really, why bother? Beneath the disguise, they remain numbers, as we can see at the bottom that aggregation like SUM() and AVERAGE() are well performed.Īgain, in Excel, data type is not well emphasized and enforced. Notice, here I have altered the format of numbers, forcing them into text format, and thus naturally aligning to the left. Formatting is just a way of altering your data appearance, without changing anything of its value. After all, it's my data and I'll give it the type I want.īack in Excel you can only disguise your data, playing with formatting options. Though, sometimes it is more disturbing than anything else and you end up deleting that step Power Query creates for you. So, the Power Query team tried to make it easy by automatically detecting column types from the imported data. Not cool, right? What's wrong with my data? It all looks good to me after all. Try creating a dataflow in the Power BI Service without specifying a data type for each column, and you will get the following message. Power Query is less friendly with typeless (or rather untyped) columns. In fact, I only started to bother about data types when starting to use Power Query, Power BI and Power Pivot (data modelling tool in Excel). We just enter values and it's all fine (somehow). It's true that in spreadsheet applications like Excel, data type is not really of a bother to the user, as there is no functionality to define the type of the data present in cells. For a beginner in Power BI and in business intelligence in general, it is not easy to understand data types and differentiate them from data format.
