You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
SELECT
DISTINCT year, country,
FIRST_VALUE(year) OVER (w ORDER BY year ASC) AS first,
FIRST_VALUE(year) OVER (w ORDER BY year DESC) AS last
FROM sales
WINDOW w AS (PARTITION BY country)
SELECT item, purchases, category, LAST_VALUE(item)
OVER (
item_window
ROWS BETWEEN 1 PRECEDING AND1 FOLLOWING
) AS most_popular
FROM Produce
WINDOW item_window AS (
PARTITION BY category
ORDER BY purchases)
Activity
alamb commentedon Oct 20, 2023
Thanks for the report @jesse-shopify -- any contributions to add such support are most welcome
LucaCappelletti94 commentedon Sep 22, 2026
Closing as completed in #1166