Files
cfw-autumn/server/tinybird/materializations/events_by_timestamp_mv_pipe.pipe
2026-05-15 12:58:30 +01:00

25 lines
607 B
Plaintext

DESCRIPTION >
Materializes events into events_by_timestamp_mv for fast time-range listing.
Copies all event columns without aggregation - just re-sorted by timestamp.
NODE transformation_node
SQL >
SELECT
id,
org_id,
env,
customer_id,
event_name,
timestamp,
value,
properties,
idempotency_key,
coalesce(entity_id, '') as entity_id,
internal_product_id,
toString(deductions) as deductions
FROM events
ORDER BY timestamp DESC, id DESC
TYPE materialized
DATASOURCE events_by_timestamp_mv