What happens if you comment out that WHERE condition? I don't know anything about your data or tables, but the most likely explanation to me is that there are no rows that fulfil the condition in the WHERE clause.
Query executed successfully but 0 rows
Whenever I am executing SQL query it says "Query executed successfully" but rows count is "0"
I have checked in Query options and "SET PARSEONLY" is not selected.
If I right click on same table and click on "Select Top 1000 rows" then I am able to see Top 1000 rows results but only this query is not returning any rows or results.
Can you please suggest solution on this issue.
3 answers
Sort by: Oldest
-
-
Laxmikant 216 Reputation points
2022-08-06T18:40:26.233+00:00 remove the where clause from Source Table CTE and try.
or
can you query select top 100 EDDateTime, * from PowerBI_Data and paste screenshot of result here.
-
Erland Sommarskog 101.4K Reputation points MVP
2022-08-07T13:17:52.657+00:00 Not sure what is wrong with my WHERE clause because 1 week back it was working fine.
Presumably, one week ago you had data for the date that was the current date then. But if the data set has not been refreshed since then, you don't have any data for today.
Also, that filtering only filters out old rows, but you can still get multiple rows for the same user. Maybe you are looking for the most recent row for each user, no matter the date?