← All studies · askamerica.ai

Volume-weighted, PG&E, Con Edison and small-mileage crude/ammonia lines top the PHMSA safety-rate rankings by pipeline type

PHMSA hazardous-liquid, gas-transmission, and gas-distribution incident and annual-mileage reports, 2010-2024

Which pipeline operators have the worst safety records, per mile run? PHMSA incident + annual mileage reports, 2010-2024, operators with 500+ avg. miles & 8+ years reported Deadliest single event, all 3 systems (2010-2024) PG&E Line 132, San Bruno CA (2010) 8 dead, 51 injured Hazardous-liquid pipelines: serious incidents / 1,000 mile-yr 0.00 0.02 0.04 0.06 0.08 0.10 0.12 Operator Per 1000 mile-yr West Texas Gulf Magellan Ammonia Dixie Pipeline Energy Transfer Explorer Pipeline Enbridge Energy LP Phillips 66 Colonial Top bars rest on n=1 serious event each over 15 years — small counts, treat as noisy, not a durable ranking. Gas distribution utilities: serious incidents / 1,000 mile-yr 0.00 0.02 0.04 0.06 0.08 0.10 0.12 Operator Per 1000 mile-yr Philadelphia Gas Works Con Edison NY KeySpan NYC CPS Energy BGE Baltimore Columbia Gas MA Peoples Gas Chicago Montana-Dakota Highest-rate pipeline system overall — gas mains run under populated areas, so a leak/explosion there hurts more people per mile than a… Gas transmission pipelines: serious incidents / 1,000 mile-yr 0.00 0.02 0.04 0.06 0.08 0.10 0.12 Operator Per 1000 mile-yr PG&E Ameren Illinois WTG Gas Transmission Atmos Pipeline TX Kinder Morgan TX Texas Eastern (Enbridge) Enogex ONEOK Gas Transp PG&E: 10 dead / 68 injured across 3 separate fatal explosions (2010, and two in 2015) over 92,560 mile-years — a repeated pattern, not one… Serious incident = at least one fatality or injury. Rates use mile-years (sum of each operator's reported annual mileage) as the exposure denominator, the standard PHMSA per-mile normalization. Small operators (<500 avg. miles or <8 years reported) excluded to avoid small-n noise. AskAmerica · askamerica.ai
SVG

Summary

Once incident counts are normalized by how much pipe an operator actually runs (mile-years of reported mileage, 2010-2024), the worst per-mile safety records are concentrated in a few names per pipeline category, and the pattern differs sharply by pipeline type. Among gas distribution utilities — the local mains running under streets and homes — Philadelphia Gas Works and Consolidated Edison of New York have the highest rates of serious (fatality/injury) incidents per 1,000 mile-years (0.110 and 0.107), and this category has the highest serious-incident rate of any of the three pipeline systems, because failures happen close to people. Among gas transmission lines, PG&E stands out not for one catastrophe but for three separate fatal explosions in 15 years (San Bruno 2010, and two more in 2015) totaling 10 deaths and 68 injuries over 92,560 mile-years operated. Among hazardous-liquid (crude/refined-product/ammonia) pipelines, several small operators — West Texas Gulf, Magellan Ammonia, Dixie Pipeline — show the highest per-mile serious-incident rates, but each rests on only one serious event over 15 years, so those rankings are statistically thin and should not be read as durable "worst" verdicts the way PG&E's repeated-pattern record can be.

Data and method

Source: PHMSA's own accident reports (Form 7000-1 for hazardous liquid, Form 7100.2 for gas transmission & gathering, Form 7100.1 for gas distribution) joined to PHMSA's operator annual reports, which carry each operator's total regulated pipeline mileage by year (Part D of each annual-report form). Both series are ingested into this warehouse's transport schema (phmsa_hazardous_liquid_incidents/_mileage, phmsa_gas_transmission_incidents/_mileage, phmsa_gas_distribution_incidents/_mileage) from data.transportation.gov's open-data mirror of the PHMSA bulk files.

Exposure denominator: for each operator, mile-years = the sum of its reported total_miles across every year 2010-2024 it filed an annual report (the standard PHMSA per-mile-year normalization, since an operator's mileage changes year to year as it builds or divests pipe). The join key is operator_id + report/activity year. Only operators reporting mileage in at least 8 of the 15 years and averaging at least 500 miles were ranked, to exclude tiny or short-lived filers whose rates are pure small-sample noise — a 1-mile operator with one incident in one year would otherwise top every list. The window 2010-2024 was chosen because incident data both extends to 2026 and mileage data is only complete through 2024; capping both series at the last year both have full annual-report coverage avoids comparing a partial 2025-2026 incident count against a mileage base that under-represents those years.

Metric: "serious incidents" (at least one fatality or one injury) per 1,000 mile-years, rather than raw incident counts, because raw counts are dominated by minor spills/leaks that scale with reporting diligence and pipeline age, not underlying hazard to people. A secondary check (raw incidents per 1,000 mile-years, and barrels spilled per mile-year) was also run for the hazardous-liquid table; it surfaces a largely different set of names (Enterprise Crude Pipeline LLC tops raw-incident-rate with 388 incidents over 52,225 mile-years, but only 1 serious event and 2 injuries in that span) — illustrating that "worst safety record" depends heavily on whether you count minor releases or people hurt, and the two rankings disagree.

Hazardous-liquid pipelines (crude oil, refined products, ammonia, etc.)

West Texas Gulf Pipeline Co58215491010.1146
Magellan Ammonia Pipeline LP1,03010401110.0970
Dixie Pipeline Co LLC1,30515181110.0511
Energy Transfer Company3,93114682110.0363
Explorer Pipeline Co1,84615841040.0361
Enterprise Products Operating LLC22,486153273560.0089
Enbridge Energy, LP4,678151211230.0143
Colonial Pipeline Co5,590152381240.0119
Colonial Pipeline Co5,590152381240.0119
Dixie Pipeline Co LLC1,30515181110.0511
Enbridge Energy, LP4,678151211230.0143
Energy Transfer Company3,93114682110.0363
Enterprise Products Operating LLC22,486153273560.0089
Explorer Pipeline Co1,84615841040.0361
Magellan Ammonia Pipeline LP1,03010401110.0970
West Texas Gulf Pipeline Co58215491010.1146
Enterprise Products Operating LLC22,486153273560.0089
Colonial Pipeline Co5,590152381240.0119
Enbridge Energy, LP4,678151211230.0143
Energy Transfer Company3,93114682110.0363
Explorer Pipeline Co1,84615841040.0361
Dixie Pipeline Co LLC1,30515181110.0511
Magellan Ammonia Pipeline LP1,03010401110.0970
West Texas Gulf Pipeline Co58215491010.1146
West Texas Gulf Pipeline Co58215491010.1146
Dixie Pipeline Co LLC1,30515181110.0511
Explorer Pipeline Co1,84615841040.0361
Enterprise Products Operating LLC22,486153273560.0089
Enbridge Energy, LP4,678151211230.0143
Colonial Pipeline Co5,590152381240.0119
Energy Transfer Company3,93114682110.0363
Magellan Ammonia Pipeline LP1,03010401110.0970
Enterprise Products Operating LLC22,486153273560.0089
Colonial Pipeline Co5,590152381240.0119
Enbridge Energy, LP4,678151211230.0143
Explorer Pipeline Co1,84615841040.0361
Energy Transfer Company3,93114682110.0363
West Texas Gulf Pipeline Co58215491010.1146
Magellan Ammonia Pipeline LP1,03010401110.0970
Dixie Pipeline Co LLC1,30515181110.0511
Enterprise Products Operating LLC22,486153273560.0089
Energy Transfer Company3,93114682110.0363
West Texas Gulf Pipeline Co58215491010.1146
Magellan Ammonia Pipeline LP1,03010401110.0970
Dixie Pipeline Co LLC1,30515181110.0511
Explorer Pipeline Co1,84615841040.0361
Enbridge Energy, LP4,678151211230.0143
Colonial Pipeline Co5,590152381240.0119
Enterprise Products Operating LLC22,486153273560.0089
Enbridge Energy, LP4,678151211230.0143
Colonial Pipeline Co5,590152381240.0119
Magellan Ammonia Pipeline LP1,03010401110.0970
Dixie Pipeline Co LLC1,30515181110.0511
Energy Transfer Company3,93114682110.0363
West Texas Gulf Pipeline Co58215491010.1146
Explorer Pipeline Co1,84615841040.0361
Enterprise Products Operating LLC22,486153273560.0089
Explorer Pipeline Co1,84615841040.0361
Colonial Pipeline Co5,590152381240.0119
Enbridge Energy, LP4,678151211230.0143
West Texas Gulf Pipeline Co58215491010.1146
Magellan Ammonia Pipeline LP1,03010401110.0970
Dixie Pipeline Co LLC1,30515181110.0511
Energy Transfer Company3,93114682110.0363
West Texas Gulf Pipeline Co58215491010.1146
Magellan Ammonia Pipeline LP1,03010401110.0970
Dixie Pipeline Co LLC1,30515181110.0511
Energy Transfer Company3,93114682110.0363
Explorer Pipeline Co1,84615841040.0361
Enbridge Energy, LP4,678151211230.0143
Colonial Pipeline Co5,590152381240.0119
Enterprise Products Operating LLC22,486153273560.0089

For comparison, the raw incident-count rate (any release, regardless of injury) is topped by different operators entirely: Enterprise Crude Pipeline LLC (7.4 incidents/1,000 mile-yr, 388 incidents, but only 2 injuries and 0 fatalities over 52,225 mile-years) and SemGroup LP (5.7). This is the reporting-diligence/minor-leak effect, not a people-safety signal.

Gas transmission pipelines

WTG Gas Transmission Co58915211000.1132
Ameren Illinois Co1,22915411000.0542
Pacific Gas & Electric Co6,17115595106830.0540
Atmos Pipeline - Texas5,642151533310.0354
Texas Eastern Transmission (Enbridge)8,838157041940.0302
Columbia Gas Transmission10,827158741750.0246
Ameren Illinois Co1,22915411000.0542
Atmos Pipeline - Texas5,642151533310.0354
Columbia Gas Transmission10,827158741750.0246
Pacific Gas & Electric Co6,17115595106830.0540
Texas Eastern Transmission (Enbridge)8,838157041940.0302
WTG Gas Transmission Co58915211000.1132
Columbia Gas Transmission10,827158741750.0246
Texas Eastern Transmission (Enbridge)8,838157041940.0302
Pacific Gas & Electric Co6,17115595106830.0540
Atmos Pipeline - Texas5,642151533310.0354
Ameren Illinois Co1,22915411000.0542
WTG Gas Transmission Co58915211000.1132
WTG Gas Transmission Co58915211000.1132
Ameren Illinois Co1,22915411000.0542
Pacific Gas & Electric Co6,17115595106830.0540
Atmos Pipeline - Texas5,642151533310.0354
Texas Eastern Transmission (Enbridge)8,838157041940.0302
Columbia Gas Transmission10,827158741750.0246
Columbia Gas Transmission10,827158741750.0246
Texas Eastern Transmission (Enbridge)8,838157041940.0302
Pacific Gas & Electric Co6,17115595106830.0540
Atmos Pipeline - Texas5,642151533310.0354
Ameren Illinois Co1,22915411000.0542
WTG Gas Transmission Co58915211000.1132
Pacific Gas & Electric Co6,17115595106830.0540
Texas Eastern Transmission (Enbridge)8,838157041940.0302
Columbia Gas Transmission10,827158741750.0246
Atmos Pipeline - Texas5,642151533310.0354
WTG Gas Transmission Co58915211000.1132
Ameren Illinois Co1,22915411000.0542
Pacific Gas & Electric Co6,17115595106830.0540
Atmos Pipeline - Texas5,642151533310.0354
WTG Gas Transmission Co58915211000.1132
Ameren Illinois Co1,22915411000.0542
Texas Eastern Transmission (Enbridge)8,838157041940.0302
Columbia Gas Transmission10,827158741750.0246
Pacific Gas & Electric Co6,17115595106830.0540
Texas Eastern Transmission (Enbridge)8,838157041940.0302
Columbia Gas Transmission10,827158741750.0246
Atmos Pipeline - Texas5,642151533310.0354
WTG Gas Transmission Co58915211000.1132
Ameren Illinois Co1,22915411000.0542
Columbia Gas Transmission10,827158741750.0246
Texas Eastern Transmission (Enbridge)8,838157041940.0302
Pacific Gas & Electric Co6,17115595106830.0540
Atmos Pipeline - Texas5,642151533310.0354
WTG Gas Transmission Co58915211000.1132
Ameren Illinois Co1,22915411000.0542
WTG Gas Transmission Co58915211000.1132
Ameren Illinois Co1,22915411000.0542
Pacific Gas & Electric Co6,17115595106830.0540
Atmos Pipeline - Texas5,642151533310.0354
Texas Eastern Transmission (Enbridge)8,838157041940.0302
Columbia Gas Transmission10,827158741750.0246

PG&E's record: 2010 San Bruno rupture (8 dead, 51 injured, confirmed against NTSB/Wikipedia reporting of the same event), plus two more fatal excavation-damage explosions in 2015 (1 dead/13 injured; 1 dead/2 injured). Three fatal events in 15 years on one system is a repeated pattern, unlike WTG Gas Transmission or Ameren Illinois, whose top-of-list rates rest on a single fatal incident out of only 2-4 total incidents filed in the entire window — statistically too thin to call a "record."

Gas distribution utilities (local mains)

Philadelphia Gas Works3,03765370.1098
Consolidated Edison Co of NY4,34953710540.1073
KeySpan Energy Delivery - NYC4,168235090.0800
CPS Energy (San Antonio)5,55066260.0721
Baltimore Gas & Electric7,325217490.0637
Columbia Gas of Massachusetts4,9241531440.0609
Baltimore Gas & Electric7,325217490.0637
Columbia Gas of Massachusetts4,9241531440.0609
Consolidated Edison Co of NY4,34953710540.1073
CPS Energy (San Antonio)5,55066260.0721
KeySpan Energy Delivery - NYC4,168235090.0800
Philadelphia Gas Works3,03765370.1098
Baltimore Gas & Electric7,325217490.0637
CPS Energy (San Antonio)5,55066260.0721
Columbia Gas of Massachusetts4,9241531440.0609
Consolidated Edison Co of NY4,34953710540.1073
KeySpan Energy Delivery - NYC4,168235090.0800
Philadelphia Gas Works3,03765370.1098
Consolidated Edison Co of NY4,34953710540.1073
KeySpan Energy Delivery - NYC4,168235090.0800
Baltimore Gas & Electric7,325217490.0637
Columbia Gas of Massachusetts4,9241531440.0609
Philadelphia Gas Works3,03765370.1098
CPS Energy (San Antonio)5,55066260.0721
Consolidated Edison Co of NY4,34953710540.1073
Baltimore Gas & Electric7,325217490.0637
CPS Energy (San Antonio)5,55066260.0721
Philadelphia Gas Works3,03765370.1098
KeySpan Energy Delivery - NYC4,168235090.0800
Columbia Gas of Massachusetts4,9241531440.0609
Consolidated Edison Co of NY4,34953710540.1073
Baltimore Gas & Electric7,325217490.0637
Philadelphia Gas Works3,03765370.1098
CPS Energy (San Antonio)5,55066260.0721
Columbia Gas of Massachusetts4,9241531440.0609
KeySpan Energy Delivery - NYC4,168235090.0800
Consolidated Edison Co of NY4,34953710540.1073
Columbia Gas of Massachusetts4,9241531440.0609
KeySpan Energy Delivery - NYC4,168235090.0800
Baltimore Gas & Electric7,325217490.0637
Philadelphia Gas Works3,03765370.1098
CPS Energy (San Antonio)5,55066260.0721
Philadelphia Gas Works3,03765370.1098
Consolidated Edison Co of NY4,34953710540.1073
KeySpan Energy Delivery - NYC4,168235090.0800
CPS Energy (San Antonio)5,55066260.0721
Baltimore Gas & Electric7,325217490.0637
Columbia Gas of Massachusetts4,9241531440.0609

Gas distribution systems, taken as a category, show the highest serious-incident rates of the three pipeline types (roughly double the top gas-transmission and hazardous-liquid rates at matched thresholds), because these mains run under sidewalks and inside buildings in dense population centers — a given leak or corrosion failure is far more likely to reach a person than the same failure on a rural transmission or crude line. Philadelphia Gas Works and Con Edison have both the highest rates and enough incidents (5-7 serious events each) that the ranking is not resting on a single event.

Caveats

Every query behind this report

11 warehouse calls ran in this session, in order. Each is reproducible against the same snapshot.

query — 1 rows — 828 ms
SELECT MIN(activity_year) min_yr, MAX(activity_year) max_yr, COUNT(*) n FROM transport.phmsa_hazardous_liquid_incidents
query — 1 rows — 767 ms
SELECT MIN(report_year) min_yr, MAX(report_year) max_yr, COUNT(*) n FROM transport.phmsa_hazardous_liquid_mileage
query — 1 rows — 778 ms
SELECT MIN(activity_year) min_yr, MAX(activity_year) max_yr, COUNT(*) n FROM transport.phmsa_gas_transmission_incidents
query — 1 rows — 718 ms
SELECT MIN(report_year) min_yr, MAX(report_year) max_yr, COUNT(*) n FROM transport.phmsa_gas_transmission_mileage
query — 25 rows — 3005 ms
WITH mileage_opyr AS (
  SELECT operator_id, report_year, SUM(total_miles) AS total_miles
  FROM transport.phmsa_hazardous_liquid_mileage
  WHERE report_year BETWEEN 2010 AND 2024
  GROUP BY operator_id, report_year
),
op_mileyears AS (
  SELECT operator_id, SUM(total_miles) AS mile_years, COUNT(DISTINCT report_year) AS years_reported,
         AVG(total_miles) AS avg_miles
  FROM mileage_opyr
  GROUP BY operator_id
),
op_names AS (
  SELECT operator_id, MAX(operator_name) AS operator_name
  FROM transport.phmsa_hazardous_liquid_mileage
  GROUP BY operator_id
),
inc AS (
  SELECT operator_id,
         COUNT(*) AS n_incidents,
         SUM(CASE WHEN fatalities_total>0 OR injuries_total>0 THEN 1 ELSE 0 END) AS n_serious,
         SUM(fatalities_total) AS fatalities,
         SUM(injuries_total) AS injuries,
         SUM(COALESCE(unintentional_release_bbls,0)) AS bbls_spilled
  FROM transport.phmsa_hazardous_liquid_incidents
  WHERE activity_year BETWEEN 2010 AND 2024
  GROUP BY operator_id
)
SELECT n.operator_name, m.operator_id, m.years_reported, ROUND(m.avg_miles,0) AS avg_miles,
       ROUND(m.mile_years,0) AS mile_years,
       COALESCE(i.n_incidents,0) AS n_incidents,
       COALESCE(i.n_serious,0) AS n_serious,
       COALESCE(i.fatalities,0) AS fatalities,
       COALESCE(i.injuries,0) AS injuries,
       ROUND(COALESCE(i.bbls_spilled,0),0) AS bbls_spilled,
       ROUND(COALESCE(i.n_incidents,0)*1000.0/NULLIF(m.mile_years,0),3) AS incidents_per_1000_mileyr,
       ROUND(COALESCE(i.bbls_spilled,0)/NULLIF(m.mile_years,0),2) AS bbls_per_mileyr
FROM op_mileyears m
JOIN op_names n ON n.operator_id = m.operator_id
LEFT JOIN inc i ON i.operator_id = m.operator_id
WHERE m.avg_miles >= 500 AND m.years_reported >= 8
ORDER BY incidents_per_1000_mileyr DESC
LIMIT 25
query — 15 rows — 2528 ms
WITH mileage_opyr AS (
  SELECT operator_id, report_year, SUM(total_miles) AS total_miles
  FROM transport.phmsa_hazardous_liquid_mileage
  WHERE report_year BETWEEN 2010 AND 2024
  GROUP BY operator_id, report_year
),
op_mileyears AS (
  SELECT operator_id, SUM(total_miles) AS mile_years, COUNT(DISTINCT report_year) AS years_reported,
         AVG(total_miles) AS avg_miles
  FROM mileage_opyr
  GROUP BY operator_id
),
op_names AS (
  SELECT operator_id, MAX(operator_name) AS operator_name
  FROM transport.phmsa_hazardous_liquid_mileage
  GROUP BY operator_id
),
inc AS (
  SELECT operator_id,
         COUNT(*) AS n_incidents,
         SUM(fatalities_total) AS fatalities,
         SUM(injuries_total) AS injuries,
         SUM(CASE WHEN fatalities_total>0 OR injuries_total>0 THEN 1 ELSE 0 END) AS n_serious,
         SUM(COALESCE(unintentional_release_bbls,0)) AS bbls_spilled
  FROM transport.phmsa_hazardous_liquid_incidents
  WHERE activity_year BETWEEN 2010 AND 2024
  GROUP BY operator_id
)
SELECT n.operator_name, m.operator_id, m.years_reported, ROUND(m.avg_miles,0) AS avg_miles,
       ROUND(m.mile_years,0) AS mile_years,
       COALESCE(i.n_incidents,0) AS n_incidents,
       COALESCE(i.fatalities,0) AS fatalities,
       COALESCE(i.injuries,0) AS injuries,
       COALESCE(i.n_serious,0) AS n_serious,
       ROUND(COALESCE(i.n_serious,0)*1000.0/NULLIF(m.mile_years,0),4) AS serious_per_1000_mileyr,
       ROUND(COALESCE(i.bbls_spilled,0)/NULLIF(m.mile_years,0),2) AS bbls_per_mileyr
FROM op_mileyears m
JOIN op_names n ON n.operator_id = m.operator_id
LEFT JOIN inc i ON i.operator_id = m.operator_id
WHERE m.avg_miles >= 500 AND m.years_reported >= 8
ORDER BY serious_per_1000_mileyr DESC
FETCH FIRST 15 ROWS ONLY
query — 15 rows — 3110 ms
WITH mileage_opyr AS (
  SELECT operator_id, report_year, SUM(total_miles) AS total_miles
  FROM transport.phmsa_gas_transmission_mileage
  WHERE report_year BETWEEN 2010 AND 2024
  GROUP BY operator_id, report_year
),
op_mileyears AS (
  SELECT operator_id, SUM(total_miles) AS mile_years, COUNT(DISTINCT report_year) AS years_reported,
         AVG(total_miles) AS avg_miles
  FROM mileage_opyr
  GROUP BY operator_id
),
op_names AS (
  SELECT operator_id, MAX(operator_name) AS operator_name
  FROM transport.phmsa_gas_transmission_mileage
  GROUP BY operator_id
),
inc AS (
  SELECT operator_id,
         COUNT(*) AS n_incidents,
         SUM(fatalities_total) AS fatalities,
         SUM(injuries_total) AS injuries,
         SUM(CASE WHEN fatalities_total>0 OR injuries_total>0 THEN 1 ELSE 0 END) AS n_serious,
         SUM(CASE WHEN explode_ind='YES' THEN 1 ELSE 0 END) AS n_explosions
  FROM transport.phmsa_gas_transmission_incidents
  WHERE activity_year BETWEEN 2010 AND 2024
  GROUP BY operator_id
)
SELECT n.operator_name, m.operator_id, m.years_reported, ROUND(m.avg_miles,0) AS avg_miles,
       ROUND(m.mile_years,0) AS mile_years,
       COALESCE(i.n_incidents,0) AS n_incidents,
       COALESCE(i.fatalities,0) AS fatalities,
       COALESCE(i.injuries,0) AS injuries,
       COALESCE(i.n_serious,0) AS n_serious,
       COALESCE(i.n_explosions,0) AS n_explosions,
       ROUND(COALESCE(i.n_incidents,0)*1000.0/NULLIF(m.mile_years,0),3) AS incidents_per_1000_mileyr,
       ROUND(COALESCE(i.n_serious,0)*1000.0/NULLIF(m.mile_years,0),4) AS serious_per_1000_mileyr
FROM op_mileyears m
JOIN op_names n ON n.operator_id = m.operator_id
LEFT JOIN inc i ON i.operator_id = m.operator_id
WHERE m.avg_miles >= 500 AND m.years_reported >= 8
ORDER BY serious_per_1000_mileyr DESC
FETCH FIRST 15 ROWS ONLY
query — 5 rows — 1423 ms
SELECT activity_year, report_number, fatalities_total, injuries_total, explode_ind, cause, cause_details
FROM transport.phmsa_gas_transmission_incidents
WHERE operator_id='15007' AND (fatalities_total>0 OR injuries_total>0)
ORDER BY activity_year
query — 1 rows — 2257 ms
SELECT MIN(activity_year) min_yr, MAX(activity_year) max_yr, COUNT(*) n FROM transport.phmsa_gas_distribution_incidents
query — 1 rows — 2445 ms
SELECT MIN(report_year) min_yr, MAX(report_year) max_yr, COUNT(*) n FROM transport.phmsa_gas_distribution_mileage
query — 15 rows — 3513 ms
WITH mileage_opyr AS (
  SELECT operator_id, report_year, SUM(total_miles) AS total_miles
  FROM transport.phmsa_gas_distribution_mileage
  WHERE report_year BETWEEN 2010 AND 2024
  GROUP BY operator_id, report_year
),
op_mileyears AS (
  SELECT operator_id, SUM(total_miles) AS mile_years, COUNT(DISTINCT report_year) AS years_reported,
         AVG(total_miles) AS avg_miles
  FROM mileage_opyr
  GROUP BY operator_id
),
op_names AS (
  SELECT operator_id, MAX(operator_name) AS operator_name
  FROM transport.phmsa_gas_distribution_mileage
  GROUP BY operator_id
),
inc AS (
  SELECT operator_id,
         COUNT(*) AS n_incidents,
         SUM(fatalities_total) AS fatalities,
         SUM(injuries_total) AS injuries,
         SUM(CASE WHEN fatalities_total>0 OR injuries_total>0 THEN 1 ELSE 0 END) AS n_serious
  FROM transport.phmsa_gas_distribution_incidents
  WHERE activity_year BETWEEN 2010 AND 2024
  GROUP BY operator_id
)
SELECT n.operator_name, m.operator_id, m.years_reported, ROUND(m.avg_miles,0) AS avg_miles,
       ROUND(m.mile_years,0) AS mile_years,
       COALESCE(i.n_incidents,0) AS n_incidents,
       COALESCE(i.fatalities,0) AS fatalities,
       COALESCE(i.injuries,0) AS injuries,
       COALESCE(i.n_serious,0) AS n_serious,
       ROUND(COALESCE(i.n_serious,0)*1000.0/NULLIF(m.mile_years,0),4) AS serious_per_1000_mileyr
FROM op_mileyears m
JOIN op_names n ON n.operator_id = m.operator_id
LEFT JOIN inc i ON i.operator_id = m.operator_id
WHERE m.avg_miles >= 3000 AND m.years_reported >= 8
ORDER BY serious_per_1000_mileyr DESC
FETCH FIRST 15 ROWS ONLY

Sources

  1. PHMSA hazardous liquid pipeline accident reports (Form 7000-1), 2010-2024
    Show tool call
    query(sql="transport.phmsa_hazardous_liquid_incidents joined to transport.phmsa_hazardous_liquid_mileage on operator_id/report_year")
  2. PHMSA gas transmission & gathering incident reports (Form 7100.2), 2010-2024
    Show tool call
    query(sql="transport.phmsa_gas_transmission_incidents joined to transport.phmsa_gas_transmission_mileage on operator_id/report_year")
  3. PHMSA gas distribution incident reports (Form 7100.1), 2010-2024
    Show tool call
    query(sql="transport.phmsa_gas_distribution_incidents joined to transport.phmsa_gas_distribution_mileage on operator_id/report_year")
  4. San Bruno pipeline explosion (Wikipedia, cross-check of PG&E fatality/injury count)
  5. NTSB Accident Report PAR-11/01, San Bruno pipeline rupture