activity request fix: order by action_id in window function

This commit is contained in:
norohind committed 2022-01-31 14:14:26 +03:00
1 parent 6d0b78dca1
commit b9cab7f667
1 file changed
+1 -1
+1 -1
View File
@@ -37,7 +37,7 @@ from
sum_score,
min(timestamp) as timestamp,
action_id,
lag (sum_score, 1) over (order by sum_score) sum_score_old
lag (sum_score, 1) over (order by action_id) sum_score_old
from (
select sum(score) as sum_score, min(timestamp) as timestamp, action_id
from squads_stats_states