Skip to content

Commit

Permalink
fix: Ignore viewports where width/height is 0 (#27160)
Browse files Browse the repository at this point in the history
  • Loading branch information
rafaeelaudibert authored Dec 26, 2024
1 parent 79a1c30 commit b09e3f0
Showing 1 changed file with 2 additions and 1 deletion.
3 changes: 2 additions & 1 deletion posthog/hogql_queries/web_analytics/stats_table.py
Original file line number Diff line number Diff line change
Expand Up @@ -564,7 +564,8 @@ def where_breakdown(self):
return parse_expr("tupleElement(breakdown_value, 2) IS NOT NULL")
case WebStatsBreakdown.VIEWPORT:
return parse_expr(
"tupleElement(breakdown_value, 1) IS NOT NULL AND tupleElement(breakdown_value, 2) IS NOT NULL"
"tupleElement(breakdown_value, 1) IS NOT NULL AND tupleElement(breakdown_value, 2) IS NOT NULL AND "
"tupleElement(breakdown_value, 1) != 0 AND tupleElement(breakdown_value, 2) != 0"
)
case (
WebStatsBreakdown.INITIAL_UTM_SOURCE
Expand Down

0 comments on commit b09e3f0

Please sign in to comment.