- Add 7 new grid regions (BPA, DUKE, SOCO, TVA, FPC, WAPA, NWMT) to cover entire continental US - Expand datacenters from 108 to 292 facilities across 39 operators - Add EIA power plant pipeline: download script, 3,546 plants >= 50 MW with diamond map markers - Rewrite backfill script for 10-year data (2015-07-01) with quarterly/monthly chunking, 3-region parallelism, resumability - Add materialized views (daily/weekly) with server-side granularity selection for chart performance - Fix map UX: z-index tooltips, disable POI clicks, move legend via MapControl
15 lines
354 B
SQL
15 lines
354 B
SQL
-- @param {String} $1:regionCode
|
|
-- @param {DateTime} $2:startDate
|
|
-- @param {DateTime} $3:endDate
|
|
SELECT
|
|
ep.timestamp,
|
|
ep.price_mwh,
|
|
ep.demand_mw,
|
|
r.code AS region_code,
|
|
r.name AS region_name
|
|
FROM electricity_prices ep
|
|
JOIN grid_regions r ON ep.region_id = r.id
|
|
WHERE r.code = $1
|
|
AND ep.timestamp BETWEEN $2 AND $3
|
|
ORDER BY ep.timestamp ASC
|