Essential Power BI DAX Functions: Quick Quiz Quiz

Assess your understanding of key Power BI DAX functions, from aggregation and date-time operations to text and logical formulas. This quiz covers the core DAX concepts every Power BI user should know, helping solidify foundational knowledge for data analysis and reporting.

  1. Current Date Function

    Which DAX function returns only the current date without the time component?

    1. TODAY()
    2. NOW()
    3. YEAR()
    4. DATE()

    Explanation: TODAY() provides just the current date, not the time. NOW() includes both date and time. YEAR() extracts the year from a date, while DATE() is used to create a date from year, month, and day values. Only TODAY() exactly matches the requirement.

  2. Calculating Difference Between Dates

    Which DAX function calculates the number of days between an order and delivery date?

    1. DATEDIFF()
    2. DIFFDATE()
    3. DAYS()
    4. DATEDAYS()

    Explanation: DATEDIFF() computes the difference between two dates, and can return results in days, months, or years. DIFFDATE(), DAYS(), and DATEDAYS() are not valid DAX functions for date differences. Only DATEDIFF() is correct for this scenario.

  3. Extracting Year from Date

    If you need to extract the year from an 'Order Date' column, which DAX function would you use?

    1. YEAR()
    2. MONTH()
    3. DAY()
    4. YEARS()

    Explanation: YEAR() returns just the year part of a date. MONTH() and DAY() return the month and day respectively. YEARS() is not a defined DAX function. Therefore, YEAR() is the suitable choice here.

  4. Summing Values in a Column

    How can you add together all numeric values in the 'Amount' column using DAX?

    1. SUM()
    2. ADD()
    3. TOTAL()
    4. PLUS()

    Explanation: SUM() calculates the total of all values in a specified column. ADD() and PLUS() are not valid DAX aggregation functions, and TOTAL() does not exist in DAX for this operation. Only SUM() correctly generates a column sum.

  5. Joining Text Values

    Which DAX function joins two pieces of text, such as combining a first and last name?

    1. CONCATENATE()
    2. COMBINE()
    3. MERGE()
    4. JOIN()

    Explanation: CONCATENATE() is used to join two text values into one. COMBINE(), MERGE(), and JOIN() are not DAX text functions for this purpose. Thus, CONCATENATE() is the accurate function to use.

  6. Finding Length of Text

    To determine the number of characters in an email address field, which DAX function should you use?

    1. LEN()
    2. LENGTH()
    3. COUNT()
    4. CHARCOUNT()

    Explanation: LEN() returns the length of a text value, i.e., the number of characters. LENGTH() and CHARCOUNT() are not recognized DAX functions, and COUNT() is used for counting values, not characters. Only LEN() serves this role.

  7. Basic IF Logic

    Which DAX function allows you to return 'High' if 'Amount' is greater than 1000, and 'Low' otherwise?

    1. IF()
    2. SWITCH()
    3. CASE()
    4. WHEN()

    Explanation: The IF() function handles simple conditional logic in DAX, letting you specify true and false results. SWITCH() is for multiple condition branches, while CASE() and WHEN() are not DAX functions. IF() is correct for basic true/false scenarios.

  8. Average Calculation

    Which function would you use to find the average profit from the 'Profit' column?

    1. AVERAGE()
    2. MEAN()
    3. AVG()
    4. MEDIAN()

    Explanation: AVERAGE() calculates the mean of all values in a column. MEAN() and AVG() are not valid DAX functions, despite similar naming, and MEDIAN() returns the median, not the average. Only AVERAGE() fits the requirement.

  9. Filtering Rows Based on Profit

    Which DAX function returns only the rows from a table where profit is less than zero?

    1. FILTER()
    2. SEARCH()
    3. WHERE()
    4. SUBSET()

    Explanation: FILTER() produces a table with only rows meeting a specified condition. SEARCH() is for finding text within text, WHERE() and SUBSET() are not valid DAX functions. Therefore, FILTER() is correct.

  10. Counting Non-Blank Values

    To count how many emails are entered in a customer table (not empty), which DAX function would you use?

    1. COUNTA()
    2. COUNTBLANK()
    3. COUNTROWS()
    4. COUNT()

    Explanation: COUNTA() counts all non-blank entries in a column, covering both text and numbers. COUNTBLANK() counts only blanks, COUNTROWS() counts all rows regardless of content, and COUNT() is mostly for non-blank numbers. COUNTA() best matches the intent.

  11. Safe Division

    In DAX, which function helps you safely divide two values and returns an alternate result if the denominator is zero?

    1. DIVIDE()
    2. SAFE_DIV()
    3. QUOTIENT()
    4. SPLIT()

    Explanation: DIVIDE() is used for division with an option to provide an alternate result on division by zero. SAFE_DIV(), QUOTIENT(), and SPLIT() are not valid DAX functions for this purpose. Thus, DIVIDE() is the right choice.

  12. Extracting First Characters from Text

    If you want the first three letters of a product code, which DAX function should you use?

    1. LEFT()
    2. RIGHT()
    3. START()
    4. MID()

    Explanation: LEFT() returns the first n characters from a text value. RIGHT() retrieves characters from the end, START() is not a DAX text function, and MID() extracts from a middle position. For the beginning characters, LEFT() is correct.

  13. Removing All Filters

    Which DAX function can you use inside CALCULATE to ignore all current filters on a table?

    1. ALL()
    2. ALLEXCEPT()
    3. CLEARFILTERS()
    4. REMOVEFILTERS()

    Explanation: ALL() removes all filters when used in CALCULATE, returning the full table context. ALLEXCEPT() retains one filter, while CLEARFILTERS() and REMOVEFILTERS() are not applicable in this DAX context. ALL() is the suitable answer.

  14. Absolute Value Function

    If you need the positive value of profit no matter if it was negative or positive, which DAX function would you use?

    1. ABS()
    2. SIGN()
    3. POS()
    4. POSITIVE()

    Explanation: ABS() returns the absolute value, always as a positive number. SIGN() indicates the sign (negative, zero, or positive) but does not return the absolute value. POS() and POSITIVE() are not DAX functions. Only ABS() is correct.

  15. Counting Unique Customer IDs

    How do you count unique customer IDs in the 'Sales' table using DAX?

    1. DISTINCTCOUNT()
    2. COUNTBLANK()
    3. COUNTA()
    4. COUNT()

    Explanation: DISTINCTCOUNT() returns the number of unique (distinct) values in a column. COUNTBLANK() finds blanks, COUNTA() counts all non-empty values, and COUNT() counts non-blank numbers. DISTINCTCOUNT() is the function for counting unique values.

  16. Rank Sales Amounts

    Which DAX function would you use to assign a rank to products based on their sales amount in descending order?

    1. RANKX()
    2. RANK()
    3. ORDERBY()
    4. ROWNUM()

    Explanation: RANKX() is used in DAX to rank values in a table based on expressions like sales amount. RANK(), ORDERBY(), and ROWNUM() are not defined as DAX ranking functions. RANKX() is the correct choice for ranking.

  17. Finding the Rightmost Characters

    To retrieve the last four characters from a product code, which DAX function is correct?

    1. RIGHT()
    2. LEFT()
    3. SUBSTRING()
    4. END()

    Explanation: RIGHT() returns the specified number of characters from the end of a text string. LEFT() gives characters from the start, SUBSTRING() and END() are not DAX functions. Thus, RIGHT() is the accurate option.

  18. Minimum Value from a Column

    What function do you use to find the lowest quantity sold from a column in DAX?

    1. MIN()
    2. SMALL()
    3. LOWER()
    4. MINIMUM()

    Explanation: MIN() finds the smallest value in a specified column. SMALL() and MINIMUM() are not present as DAX aggregation functions, and LOWER() relates to text case not values. MIN() is the correct function.

  19. Checking Single Selected Value

    Which DAX function checks if only one value is selected in a table column?

    1. HASONEVALUE()
    2. ONLYONE()
    3. ONEVALUE()
    4. SINGLE()

    Explanation: HASONEVALUE() determines if a column contains only a single selected value. ONLYONE(), ONEVALUE(), and SINGLE() do not exist as DAX functions for this use case. HASONEVALUE() is accurate.

  20. Changing Context for Calculations

    Which DAX function is essential to use when you want to modify filter context for a calculation?

    1. CALCULATE()
    2. SUMX()
    3. FILTER()
    4. EVALUATE()

    Explanation: CALCULATE() is used to evaluate an expression in a different filter context. SUMX() and FILTER() have their purposes, but do not directly modify context, and EVALUATE() is not a DAX function in this environment. CALCULATE() fits the requirement.

  21. Messages with Multiple Choices

    If you want to return specific results for multiple possible values, which DAX function lets you do that efficiently?

    1. SWITCH()
    2. CASEOF()
    3. MATCH()
    4. IFX()

    Explanation: SWITCH() makes it easy to return different results for several possible values, streamlining multiple IF statements. CASEOF(), MATCH(), and IFX() are not correct DAX functions for this. SWITCH() is the appropriate option.