MetallicPriest
MetallicPriest

Reputation: 30825

How can I get one column after a filter with DAX in PowerBI

Lets say I have a date table which contains many fields. However I just want to get the week column from it, how can I do that?

I was able to apply the filter like this.

today = FILTER('date', 'date'[Date] = TODAY())

But here today has many fields, while I just want to return the week. Basically I would like the equivalent of something like this.

todays_week = GET_COLUMN(FILTER('date', 'date'[Date] = TODAY()), 'Week')

Upvotes: 0

Views: 13917

Answers (1)

msta42a
msta42a

Reputation: 3741

We can calculate this like that:

todays_week = CALCULATETABLE(VALUES('date'[week]), 'date'[Date] = TODAY())

Upvotes: 1

Related Questions