Questions tagged [dax]

Expression language used in Microsoft Power Pivot, Analysis Services, and Power BI for performing analytical calculations.

DAX stands for Data Analysis eXpressions, an expression language created by Microsoft for performing custom analytical calculations within the Power Pivot add-in for Excel, Analysis Services, and Power BI.

DAX functions work on a column or table level to make use of the underlying compression technology used in PowerPivot.

Expressions created in DAX can be used in several ways:

  1. In calculated columns, evaluating the function on a row-by-row basis over an entire table.
  2. In measures, which may be manipulated and aggregated differently, depending on context.
  3. To return a tabular resultset when a table expression is evaluated (fills role of a general purpose query language)
  4. To create a calculated table in a Power BI model as part of the modelling process

Useful Links

8483 questions
1
vote
1 answer

Using Column names VS using A whole table in ALL Function (DAX)

Okay, SO I am trying to understand the behavior of FILTER(ALL) Function in DAX. I have created two DAX Expressions 1. sales 100 using table in ALL = CALCULATE( [Customer sales], FILTER( ALL('Sales by Store'), …
chexxmex
  • 117
  • 1
  • 8
1
vote
2 answers

Follow-up Dax Drop Duplicates

Similiar to a question asked here, Given, this table, I want to only keep the records where the email appears…
Scott Boston
  • 147,308
  • 15
  • 139
  • 187
1
vote
1 answer

Power BI, rule management (inner join)

I have to do in DAX this code, for simplicity I write it in SQL, practically I have to translate this SQL in DAX: select 'id' from x , y where x.client == y.client I can't figure it out because I can't understand how to make this kind of join in…
SilverJack
  • 47
  • 8
1
vote
1 answer

Trying to Understand CALCULATE and FILTER in DAX

I am trying to play around with FILTER and CALCULATE DAX expressions. I would like to find out the no of distinct orders which have products whose price is less than the average cost of the category: Bikes. First I am creating a Measure to calculate…
chexxmex
  • 117
  • 1
  • 8
1
vote
2 answers

Count with multiple criteria selection

I am rather new with Power BI and came across a situation I don't know how to resolve. I have 2 tables: one with users which contains the user ID and 4 criteria And one with apartments For each table, I need to create the 6th column: in the User…
1
vote
1 answer

In DAX (not powerquery) drop duplicates based on column

In my PowerBI desktop, I have table that is calculated from over other tables with a structure like this: Input table: …
Scott Boston
  • 147,308
  • 15
  • 139
  • 187
1
vote
0 answers

Power BI Between two Values

I've got a problem in PowerBI which im trying to solve for quite a while now. I made a histogram which shows me how often a value exists. For the values I have a upper and lower limit. Also I want to have a vertical targetline which shows me where…
FlorianO
  • 15
  • 1
  • 7
1
vote
1 answer

Power BI: Split columns into rows

I have something similar to this: what I want is to get a structure similar to this one: Item | Period | Qty ---------------------- Item A | 1 | 2 Item A | 2 | 2 Item B | 1 | 1 Item B | 2 | 1 Item C | 1 | 1 Item C | …
n0e
  • 309
  • 3
  • 12
1
vote
1 answer

Selected filters by default - Power BI

Imagine that I have a column with the following values: [A1,A2,A3,A4,T1,T2,T3] Now, I have a slicer with the mentioned column, but I need that the the "Ts" (T1,T2 and T3) are always selected / filtered and when I choose a specific "A" (A1) for…
Aibloy
  • 137
  • 3
  • 10
1
vote
1 answer

PowerBI dynamic table with measures

PBI Newbie here. I'm trying to create a dynamic dable using the following syntax: Test = { ("Measure 1", 'StandardKPIs'[Current measure1 value], 'StandardKPIs'[Previous measure1 value]), ("Measure 2", 'StandardKPIs'[Current measure1 value],…
Gabz
  • 77
  • 1
  • 11
1
vote
1 answer

How to create start and end date columns from date column in Power BI?

I need to make the start date and end date columns from the date column. I have a table of employees and the dates on which they are on the vacation but I need to reduce the table so that there is no separate row for each date if that date is part…
1
vote
2 answers

Showing the a column as text in Power Pivot Table next to a summarized variable (Power Pivot)

I have an Excel table like this: AZIENDA | CF | Fatturato | Semester A | 333d| 10 | 1 A | 333d| 20 | 2 B | 145 | 34 | 1 B | 145 | 10 | 2 C | 111 | 5 |…
coelidonum
  • 523
  • 5
  • 17
1
vote
1 answer

Trying to use Dax to compare the Current Sales to the MTD Sales

okay so basically lets say in the month of December (Using a Slicer of Dec 1st to Dec 10th) I want to get 2 numbers the MTD and the sales for only the current date so in this case I want to Compare Dec 10th to the entire MTD for December the MTD…
1
vote
1 answer

Variance between row values in same table based on selected filter values - Power BI

I am trying to return the variance values between rows based off of multiple filter values. Data set looks like this: Bid Name Service Area Task Name Resource Hours Revenue Bid 1 SA1 Fix the lights R1 75 100 Bid 2 SA1 Fix the…
DataNinja
  • 67
  • 1
  • 9
1
vote
2 answers

Harvesting multiple Slicers [Power BI]

For a scorecard, I need to weigh some categories based on importance. Said weights must be selectable from a filter based on their category (categories might have different weights). I created a table with the weights with the percentages to…
Btriggered
  • 11
  • 3
Firstname