Understanding the basics of DAX
One of the key differences in DAX is that it is used to build expressions and formulas, not traditional style queries. SQL works with tabular sets of data and MDX works with multidimensional sets. DAX was designed more like Excel functions. This works well when creating calculated measures and calculated columns. So, unlike MDX and SQL, there is no SELECT … FROM … WHERE structure. There are a few other concepts we need to review before we start creating calculations.
When working with DAX, you need to consider the context the function applies to. When creating calculated columns, the context is the row. You can use anything in the row to help build the column with DAX. Other functions apply to the table or just the column. When creating DAX calculations, you need to check the context to make sure you are using the function correctly.
Table names and field names use special syntax. Table names are typically enclosed in single quotes...