Get the data

Free. You will be asked to confirm an email address before the files are built — that is the only gate, and it is there so we can tell you when a large export is ready.

Preview the first 100 rows

What this is

RRC's weekly OIL/ICE extract, published on Mondays, is TWO }-delimited files, and this is the smaller of them: VIOLATIONS.txt, the inspections that found something. Its companion INSPECTIONS.txt — every completed inspection, whether it found anything or not — is published beside it as RRC Oil / ICE Inspections, and the two are meant to be read together.

Each row is one violated statewide rule at one inspected location: the rule and its description, whether RRC's technical review classed it major, whether the operator was compliant when an inspector came back, the last enforcement action and its date, and the date the rule was first marked non-compliant. One inspection can produce several rows, one per rule.

It names the operator, the P-5 number, the lease or gas well ID, the API number and the drilling permit number, so a violation can be tied to a specific hole in the ground.

396,093 rows in the load of 2026-08-17, against 3,981,260 inspections — so about one inspection in ten writes up a rule.

What you can do with it

Find an operator's compliance record, count major violations by district, and see how long it takes for a violation to be cleared.

Join to RRC Oil / ICE Inspections to turn a citation rate into a hit rate: the violation carries the location and the discovery date, and the inspection file carries every visit to that location whether or not it found anything.

Join to the wellbore and permit datasets to put a violation on a map.

Gotchas

Absence of a violation is not evidence of compliance; without the inspections file beside it, it may only mean no inspection happened. That is the whole reason both halves are published.

Dates in this file are text as published — eight characters, YYYYMMDD — not parsed dates. `to_date(violation_disc_date, 'YYYYMMDD')` before comparing one to a real date. The inspections file's own `inspection_date` IS a parsed date, so a join across the two has to convert this side.

The manual documents MAJOR_VIOL_IND and COMPLIANT_ON_REINSP as Yes / No; the file writes 'Y' and 'N', and writes '--' rather than the manual's single dash where no backcheck inspection has happened. Measured 2026-08-21: 395,850 'N' against 243 'Y' on the major flag, and 230,928 / 33,540 / 131,625 on the backcheck.

RRC warns that a field can be blank or hold a placeholder ('unknown', '00000') where the inspector did not have the information.

Record layout

18 columns.

inspections_violations 18 columns

Record layout for inspections_violations — 18 columns
# Column Type RRC name Meaning Lookup
1 operator_name text OPERATOR_NAME The operator of the inspected lease, well, facility or site AT THE TIME OF THE INSPECTION -- not whoever operates it now. Where the operator was unknown the inspector wrote down the best name available, so this is not a clean key: join on the P-5 number. e.g. HELTON, PAT A. & ALBERTA
2 p5_operator_no join text P5_OPERATOR_NO The cited operator's six-digit RRC P-5 number, as of the inspection. Join to the P-5 organization directory for today's name and status -- cast to integer first, because that directory keys on an integer. e.g. 374805
3 district join text DISTRICT The RRC completion district of the assigned oil lease or gas well ID at the time of the inspection, written the way RRC prints it (01-06, 6E, 7B, 7C, 08, 8A, 09, 10). Where the inspected site has no assigned lease or well ID, it is instead the Oil & Gas district the site sits in. Not the same question as the office that sent the inspector. e.g. 10 RRC district (printed designation)
4 oil_lease_gas_well_id join text OIL_LEASE_GAS_WELL_ID The oil lease number (five digits) or gas well ID (six digits) the violation was written against. Unique only within its district and its schedule, and blank where the inspected site was a facility. e.g. 146199
5 lease_fac_name text LEASE_FAC_NAME The name of the oil or gas lease, or of the facility, at the time of the inspection. e.g. ARNOLD
6 api_no join text API_NO The API number of the cited wellbore, eight digits: the three-digit county code then RRC's five-digit unique number, with no 42 state prefix. Split it back into its halves to reach the wellbore database. e.g. 17907011
7 county text COUNTY The name of the county the inspection was conducted in, upper case. A NAME, not a code -- this file carries no county number at all, which is why no county code set is bound to it. e.g. GRAY
8 well_no text WELL_NO The operator-assigned well number of the inspected completion at the time of the inspection. Free text as the operator designates it, so '2 L' and '515' are both normal. e.g. 13
9 drilling_permit_no join text DRILLING_PERMIT_NO Drilling permit number, where the violation attaches to a permitted well. Usually recorded only where the inspection was made before the well was completed, so it is rare.
10 field_name text FIELD_NAME The field associated with the inspected lease, well, facility or site at the time of the inspection, as a NAME. The eight-digit field number is not in this file; the field directory is where names meet numbers. e.g. PANHANDLE, WEST
11 violated_rule text VIOLATED_RULE The statewide rule found non-compliant and certified so in RRC's technical review, as RRC writes it: 'SWR 3.8(d)(1)', 'SWR 3.14(b)(2)'. The five commonest are unpermitted disposal of oil and gas wastes (75,896 rows), inactive unplugged well (66,530), well sign (64,857), surface control of well (27,687) and entrance sign (25,221). e.g. SWR 3.13(a)(6)(A)
12 violated_rule_desc text VIOLATED_RULE_DESC A short description of the violated statewide rule. e.g. Surface Control of Well
13 major_viol_ind text MAJOR_VIOL_IND Whether RRC's technical review classed the violation as major. The manual says Yes / No; the file writes 'Y' (243 rows) and 'N' (395,850). e.g. N
14 compliant_on_reinsp text COMPLIANT_ON_REINSP Whether a later backcheck inspection found the rule compliant: 'Y' 230,928 rows, 'N' 33,540, and '--' on 131,625 where no backcheck has been performed. The manual writes that last one as a single dash; the file writes two. e.g. Y
15 last_enf_action text LAST_ENF_ACTION The most recent enforcement action RRC's Oil and Gas Division took over this violation, spelled out rather than coded. Seven values in the whole file: Notice of Violation (292,520), referred to Austin Field Ops for possible legal enforcement (48,901), referred to state-managed plugging (39,231), a severance/seal order (11,444), referred to the state-managed cleanup programme (2,989), violation corrected (999), and blank on 9. e.g. Notice of Violation
16 last_enf_action_date text LAST_ENF_ACTION_DATE The date RRC's technical reviewer last reviewed and certified that enforcement action. TEXT as published, eight characters YYYYMMDD, not a parsed date -- `to_date(last_enf_action_date, 'YYYYMMDD')`. e.g. 20260203
17 violation_disc_date text VIOLATION_DISC_DATE The FIRST date an inspector marked this statewide rule non-compliant -- not the date of the most recent visit. Text as published, YYYYMMDD. It is the column that meets the inspection file's `inspection_date`, and because it stays at the first discovery, a backcheck that finds the rule still broken is another non-compliant inspection carrying an older discovery date. e.g. 20260202
18 ingested_at timestamptz When the upstream pipeline last wrote this row. Not an RRC field — it is EZRRC's provenance stamp, and it is what the freshness badge is measured against.

Code lookups used here

Every coded column in this dataset resolves to a real lookup table, so a well code of G can be read as what it actually means.

RRC district (printed designation) 14 values

Read by district

The district as the Railroad Commission prints it: 01-06, 6E, 7B, 7C, 08, 8A, 09 and 10, plus 20 for statewide. This is what appears on permits, completions, ST-1 filings and inspection reports. It is not interchangeable with the internal district number. A column holding '11' means District 8A under the internal numbering and nothing at all under this one.

RRC district (printed designation) — 14 codes and their meanings
CodeMeans
01 District 01 — San Antonio RRC District 01, administered from the San Antonio district office.
02 District 02 — San Antonio RRC District 02, administered from the San Antonio district office.
03 District 03 — Houston RRC District 03, administered from the Houston district office.
04 District 04 — Corpus Christi RRC District 04, administered from the Corpus Christi district office.
05 District 05 — Kilgore RRC District 05, administered from the Kilgore district office.
06 District 06 — Kilgore RRC District 06, administered from the Kilgore district office.
6E District 6E — Kilgore RRC District 6E, administered from the Kilgore district office.
7B District 7B — Abilene RRC District 7B, administered from the Abilene district office.
7C District 7C — San Angelo RRC District 7C, administered from the San Angelo district office.
08 District 08 — Midland RRC District 08, administered from the Midland district office.
8A District 8A — Midland RRC District 8A, administered from the Midland district office.
09 District 09 — Wichita Falls RRC District 09, administered from the Wichita Falls district office.
10 District 10 — Pampa RRC District 10, administered from the Pampa district office.
20 District 20 — State Wide RRC District 20, administered from the State Wide district office.

Source: Generated from texas.pdq_gp_district.district_name

What this joins to

The Railroad Commission never states these keys anywhere in the files. They are the reason the data is hard to use, so here they are with the exact columns on both sides.

RRC Oil / ICE Violations joins to RRC Oil / ICE Inspections (Every Inspection) on P5 operator number = P5 operator number and Oil lease gas well ID = Oil lease gas well ID and API number = API number and Well number = Well number and District = District and Violation disc date = Inspection date — many rows here share a single row there.

was found during

The inspection this violation was written at: the same inspected location, on the day the rule was first marked non-compliant. Neither file carries an inspection number, so this is the join, and it holds — 2,954 of 3,000 sampled violations find an inspection, 2,835 of them exactly one and 119 more than one (a location inspected twice on one day). One inspection can carry several violations, one per rule. The two sides are different types: this file publishes its dates as eight characters of text and the inspections file's date is a real date, so cast with `to_date(violation_disc_date, 'YYYYMMDD')`. The other five columns are text on both sides and compare as printed. Going the other way is weaker on purpose: 2,115 of 3,000 sampled NON-COMPLIANT inspections find a violation on this key. `violation_disc_date` stays at the FIRST discovery, so a backcheck that finds the same rule still broken is another non-compliant inspection carrying an older date.

rrc-oil-ice-inspections.p5_operator_no = rrc-oil-ice-inspections-detail.p5_operator_no AND rrc-oil-ice-inspections.oil_lease_gas_well_id = rrc-oil-ice-inspections-detail.oil_lease_gas_well_id AND rrc-oil-ice-inspections.api_no = rrc-oil-ice-inspections-detail.api_no AND rrc-oil-ice-inspections.well_no = rrc-oil-ice-inspections-detail.well_no AND rrc-oil-ice-inspections.district = rrc-oil-ice-inspections-detail.district AND rrc-oil-ice-inspections.violation_disc_date = rrc-oil-ice-inspections-detail.inspection_date

RRC Oil / ICE Violations joins to P-5 Organization (ASCII) on P5 operator number = ID — many rows here share a single row there.

cited the operator

The P-5 number of the operator cited in the violation, resolved to the operator directory. These two columns are different types — one is text, the other an integer — so a direct equality is rejected by Postgres. Cast the text side to integer, which also disposes of any leading zeros; casting the integer to text would not, because '000123' and 123 are not equal as text.

rrc-oil-ice-inspections.p5_operator_no = p5-organization-ascii.id

RRC Oil / ICE Violations joins to Drilling Permit Master on Drilling permit number = Permit number — many rows here share a single row there.

cited a well permitted by

The same permit number against the daf802 permit master, which is the whole W-1 history rather than the bores one file happens to list: 8,123 of the 8,191 violations that carry a permit number find a permit. These two columns are different types — one is text, the other an integer — so a direct equality is rejected by Postgres. Cast the text side to integer, which also disposes of any leading zeros; casting the integer to text would not, because '000123' and 123 are not equal as text.

rrc-oil-ice-inspections.drilling_permit_no = drilling-permit-master.permit_no

RRC Oil / ICE Violations joins to Wellbore Drilling Permit Numbers on Drilling permit number = Permit number — rows can match many rows in both directions.

cited a well permitted as

The drilling permit number on the violation, matched against the wellbore file's permit list — which is what puts an enforcement action on a specific hole in the ground. Only 8,191 of 396,093 violations carry a permit number at all, and 5,403 of those find a wellbore this way; the daf802 master below finds 8,123 of the same rows, because the wellbore file lists the permits it knows a bore by rather than every permit RRC issued. Both sides are text and it runs as printed.

rrc-oil-ice-inspections.drilling_permit_no = wellbore-drilling-permit-numbers.permit_number

Where this comes from

Published by
Texas Railroad Commission — the original page
Original format
Delimited Separated text, usually with an unusual delimiter such as a brace.
RRC publishes
Updated once a week (Weekly, on Mondays.)
RRC download link
GoAnywhere MFT
Record layout manual
Our table
texas.inspections_violations

EZRRC is an independent mirror of public-domain data published by the Texas Railroad Commission. It is not affiliated with or endorsed by the RRC. For any legal or regulatory purpose, verify against the official RRC release.