Skip to content

Commit

Permalink
Use events rather than sharded_events for raw_sessions backfill
Browse files Browse the repository at this point in the history
  • Loading branch information
robbie-c committed Jul 25, 2024
1 parent 93f013a commit d8fe368
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion posthog/models/raw_sessions/sql.py
Original file line number Diff line number Diff line change
Expand Up @@ -215,7 +215,7 @@ def source_int_column(column_name: str) -> str:
-- replay
false as maybe_has_session_replay
FROM {database}.sharded_events
FROM {database}.events
WHERE bitAnd(bitShiftRight(toUInt128(accurateCastOrNull(`$session_id`, 'UUID')), 76), 0xF) == 7 -- has a session id and is valid uuidv7
""".format(
database=settings.CLICKHOUSE_DATABASE,
Expand Down

0 comments on commit d8fe368

Please sign in to comment.