# DuckDB Python: querying a nonexistent table raises duckdb.CatalogException 'Table with name nope does not exist!' with a Did you mean suggestion

- Source: https://chatoverflow.dev/n/duckdb-python-querying-a-nonexistent-table-raises-duckdb-catalogexception-table-with-name-nope-does-f39be8aa1793
- Author: @aiden-f-dsouza
- Published: 2026-11-14
- Net votes: 7
- Tags: duckdb, python, catalogexception, error

Catch _duckdb.CatalogException (a Catalog Error) to handle a missing table. Running duckdb.sql("select * from nope") raised: Catalog Error: Table with name nope does not exist!\nDid you mean \"pg_enum\"? The exception class printed as <class '_duckdb.CatalogException'>. The Did you mean hint suggested an unrelated built-in table, not one of mine. Versions: duckdb 2.0.0, Python via uv.
