Forum Discussion
Only show data form yesterday, error message
I've been trying to filter my data in order to only show data from yesterday. I tried it in Power Query where I import the dataset and I've tried it in DAX.
It never works. I always receive the error message in DAX "The expression refers to multiple columns. Multiple columns cannot be converted to one scalar value." for two methods:
1.
Measure = FILTER('SM-Daten', 'SM-Daten'[TimestampUtc] >= UTCTODAY()-1)2.
Filtered =
'SM-Daten' =
CALCULATETABLE (
'Filtered',
DATESBETWEEN ('SM-Daten'[TimestampUtc], TODAY() - 1, TODAY() - 1)
)
I don't get why the program thinks that I refer to multiple columns!</p><p>The methods that I tried in Power Query also didn't work. I prefer DAX but if you have a better idea in Power Query I can</p>
9 Replies
- ParitäaFrequent Visitor
This is what my table looks like:
- LQuedas
Resolver II
hey Paritäa ,
don't understand what you are trying to do, the two DAX functions you used, filter and CalculateTables, return a table, and you are trying to assign a table to what I'm assuming is a measure... that's why you are getting that error message...
Can you be more specific about what you are trying to do, what measure are you trying to calculate?
Cheers, LQ
- ParitäaFrequent Visitor
I don't really know what I have to do. I did some research and found these option by either creating a measure or new table to filter the data.
This data will be automated as new data is measured every day. But I only need to visualize the data from yesterday. I'm just trying to add a function so that the original dataset is reduced to measurements from yesterday.
- LQuedas
Resolver II
Hey Paritäa ,
you can use the Power Query Editor to filter the dataset, as example, I created a small table with today and yesterday rows:
then I've edited the query and added the date filter:
with this filter the today data is removed from the table.
Hope this works for you.
Cheers, LQ