{"slug":"flash-crash-2010","qid":"aftermath","label":"The aftermath: when the May 5 close was reclaimed, and when the panic low broke for real","post_title":"The 2010 Flash Crash, Minute by Minute","post_url":"/blog/flash-crash-2010#q-aftermath","columns":["flash_crash_low","may5_close","first_close_above_may5","sessions_until_reclaim","first_close_below_low","close_that_session","sessions_until_break"],"rows":[{"flash_crash_low":105,"may5_close":116.83,"first_close_above_may5":"2010-05-12","sessions_until_reclaim":4,"first_close_below_low":"2010-06-29","close_that_session":104.22,"sessions_until_break":37}],"shape":"scalar","sql":"WITH\n    (\n        SELECT minIf(toFloat64(low), (toHour(toTimeZone(window_start, 'America/New_York')) * 60 + toMinute(toTimeZone(window_start, 'America/New_York'))) BETWEEN 570 AND 959)\n        FROM global_markets.delayed_stocks_minute_aggs\n        WHERE ticker = 'SPY'\n          AND window_start >= toDateTime('2010-05-06 04:00:00') AND window_start < toDateTime('2010-05-07 00:00:00')\n    ) AS flash_low\nSELECT\n    round(any(flash_low), 2) AS flash_crash_low,\n    round(any(may5_close), 2) AS may5_close,\n    toString(any(first_above_date)) AS first_close_above_may5,\n    countIf(et_date > toDate('2010-05-06') AND et_date <= first_above_date) AS sessions_until_reclaim,\n    toString(any(first_below_date)) AS first_close_below_low,\n    round(anyIf(close_usd, et_date = first_below_date), 2) AS close_that_session,\n    countIf(et_date > toDate('2010-05-06') AND et_date <= first_below_date) AS sessions_until_break\nFROM (\n    SELECT et_date, close_usd, flash_low, may5_close,\n           min(if(et_date > toDate('2010-05-06') AND close_usd < flash_low, et_date, toDate('2100-01-01'))) OVER () AS first_below_date,\n           min(if(et_date > toDate('2010-05-06') AND close_usd > may5_close, et_date, toDate('2100-01-01'))) OVER () AS first_above_date\n    FROM (\n        SELECT et_date, close_usd, flash_low,\n               max(if(et_date = toDate('2010-05-05'), close_usd, 0)) OVER () AS may5_close\n        FROM (\n            SELECT\n                toDate(toTimeZone(window_start, 'America/New_York')) AS et_date,\n                round(argMaxIf(toFloat64(close), window_start, (toHour(toTimeZone(window_start, 'America/New_York')) * 60 + toMinute(toTimeZone(window_start, 'America/New_York'))) BETWEEN 570 AND 959), 2) AS close_usd,\n                flash_low\n            FROM global_markets.delayed_stocks_minute_aggs\n            WHERE ticker = 'SPY'\n              AND window_start >= toDateTime('2010-05-05 04:00:00') AND window_start < toDateTime('2011-01-01 00:00:00')\n            GROUP BY et_date\n        )\n    )\n)","computed_at":"2026-07-26T05:29:34.108275+00:00","elapsed":0.208084462}