# DuckDB error codes

> Every DuckDB exception class, from Binder Error to Out of Memory, with the exact error text DuckDB returns and full write-ups of the ones you meet most.

Source: https://sqlly.app/errors/duckdb
Last updated: 2026-11-30
License: Text and data [CC BY 4.0](https://creativecommons.org/licenses/by/4.0/) (credit SQLly, sqlly.app); code and SQL snippets [MIT](https://opensource.org/license/mit). [Details](https://sqlly.app/license).
Note: Quoted error message text belongs to its database vendor.

DuckDB does not use numeric error codes. Every failure is an exception class such as `Binder Error` or `Conversion Error`, printed at the start of the message, with the details after the colon. The ones you are likely to meet have a full page with causes and fixes.

## Reading a DuckDB error

DuckDB raises exception classes instead of codes. The class name is the prefix of the message, for example `Binder Error: Column "x" not found`. Match on the prefix for the broad kind of problem and on the message text for the exact one.

Drivers surface the classes differently: Python raises `duckdb.BinderException`, `duckdb.ConversionException` and friends, while ADO.NET and JDBC wrap everything in their own exception types and carry the DuckDB message as text. Check `ExceptionType` or the message prefix, never a code.

Two classes mean very different things despite similar names: `Conversion Error` is a value that cannot be cast, and `Out of Range Error` is arithmetic overflow inside an operation.

A `Catalog Error` almost always means you are connected to a different database than you think, so check what tables actually exist before rewriting the query.

## Binder Error

- [`Binder Error`](https://sqlly.app/errors/duckdb/binder-error): DuckDB could not plan the query
- [`Binder Error`](https://sqlly.app/errors/duckdb/column-not-exist): The column is not in the FROM clause

## Catalog Error

- [`Catalog Error`](https://sqlly.app/errors/duckdb/catalog-table-not-exist): The table does not exist in this database
- [`Catalog Error`](https://sqlly.app/errors/duckdb/catalog-table-exists): The table or object already exists
- [`Catalog Error`](https://sqlly.app/errors/duckdb/catalog-schema-not-exist): The schema does not exist in this database
- `Catalog Error`: The column name is already taken

## Conversion and range errors

- [`Conversion Error`](https://sqlly.app/errors/duckdb/conversion-could-not-convert): The value cannot be cast to the target type
- [`Conversion Error`](https://sqlly.app/errors/duckdb/conversion-out-of-range): The value is out of range for INT32
- [`Conversion Error`](https://sqlly.app/errors/duckdb/conversion-invalid-date): The date or timestamp string is malformed
- `Out of Range Error`: Arithmetic overflow

## Constraint Error

- [`Constraint Error`](https://sqlly.app/errors/duckdb/constraint-not-null): A NOT NULL column received NULL
- [`Constraint Error`](https://sqlly.app/errors/duckdb/constraint-unique): A duplicate key violates a unique constraint
- [`Constraint Error`](https://sqlly.app/errors/duckdb/constraint-check): A CHECK constraint rejected the row

## IO and permission errors

- [`IO Error`](https://sqlly.app/errors/duckdb/io-file-not-found): A file could not be opened
- `IO Error`: Permission to the file was denied
- [`IO Error`](https://sqlly.app/errors/duckdb/io-lock): The database file is locked by another process
- `Permission Error`: DuckDB policy refused the operation

## Memory and resource errors

- [`Out of Memory Error`](https://sqlly.app/errors/duckdb/out-of-memory): The query hit DuckDB's memory limit
- `Interrupted Error`: The query was cancelled

## Parser and syntax errors

- [`Parser Error`](https://sqlly.app/errors/duckdb/parser-syntax-error): The SQL does not parse

## Function errors

- `Catalog Error`: The function does not exist
- `Invalid Input Error`: An invalid regular expression
- `Invalid Input Error`: Malformed JSON input
- `Binder Error`: No overload matches the argument types

## Extension and feature errors

- `Not implemented Error`: A feature DuckDB lacks was requested
- [`Serialization Error`](https://sqlly.app/errors/duckdb/serialization-error): The database file version is incompatible

## Transaction errors

- `TransactionContext Error`: The transaction hit a conflict

## Type errors

- `Invalid type Error`: A type was used where it is not supported

Codes and messages are from the [DuckDB documentation](https://duckdb.org/docs/).
