01P01WARNINGTier 2 — Caution✅ HIGH confidencedeprecated feature
What this means
SQLSTATE 01P01 is a Postgres-specific warning raised when a client uses a syntax, function, or feature that is deprecated and scheduled for removal in a future version. The statement still executes but may break on upgrade.
Why it happens
- 1Using deprecated SQL syntax or functions that Postgres has marked for removal
- 2Using removed GUC parameter names that have been renamed
- 3Relying on implicit casts or behaviours that Postgres is phasing out
How to reproduce
Using a deprecated function or syntax.
-- Example: using deprecated timestamp without timezone implicit coercion
SET standard_conforming_strings = off; -- deprecated in some configurationsFix 1: Replace deprecated usage with the recommended alternative
When 01P01 warnings appear in logs, especially before a major version upgrade.
Why this works
Read the Postgres release notes for the version where the deprecation was announced and apply the recommended migration path before upgrading.
What not to do
Ignore 01P01 warnings before a major upgrade
Why it's wrong: Deprecated features are removed in subsequent major versions, causing failures after upgrade.
Version notes
All major versionsReview the Postgres release notes under "Deprecated Features" for each major version.Sources
📚 Official docs: https://www.postgresql.org/docs/current/errcodes-appendix.html
🔧 Source ref: Class 01 — Warning (Postgres-specific)
📖 Further reading: PostgreSQL Release Notes
Confidence assessment
✅ HIGH confidence
Postgres-specific extension to the SQL standard warning class. Widely used for deprecation notices across major versions.
See also
🔗 Related errors
📄 Reference pages