What does HRESULT 0xC80004B3 (hrDatabaseNotFound) mean?

 
Previous Next
hrDatabaseInUse hrDatabaseInvalidName

hrDatabaseNotFound

The object and state that matter

hrDatabaseNotFound means a valid database name or path did not resolve to an attached or existing database.

This is the legacy Directory Service backup/restore HRESULT form of JET_errDatabaseNotFound (0xC80004B3).

The key comparison is: hrInvalidDatabaseId is a bad handle; this code is a lookup failure by database identity. The first useful observation is to capture the canonical path, attachment list, working directory, case/normalization, and file existence. This evidence separates file identity, attachment, open-handle ownership, lock state, and structural validity.

Minimum useful trace

  • Code-specific observation: capture the canonical path, attachment list, working directory, case/normalization, and file existence.
  • the canonical database path and file identity; associate it with this result rather than with a later generic exception.
  • the instance attachment list plus every session-scoped JET_DBID; associate it with this result rather than with a later generic exception.
  • open tables, transactions, maintenance, and recovery activity using the database.

How to avoid a false diagnosis

hrDatabaseLockedthe database is locked against the requested access mode
hrInvalidDatabasethe selected file is not a usable ESE database for this operation
hrDatabaseInvalidPagesthe requested initial or maximum database size is not a valid page count

The ESE objects in play

Diagnostic layerdatabase file, attachment state, JET_DBID ownership, and database lifecycle
Typical API surfaceJetCreateDatabase, JetAttachDatabase, JetOpenDatabase, JetCloseDatabase, and JetDetachDatabase
Code-specific conditiona valid database name or path did not resolve to an attached or existing database
First corrective directionlocate or attach the correct database instead of creating an empty replacement automatically

Attachment is an instance relationship; opening a database returns a session-scoped database ID. Close and detach are separate lifecycle steps and can fail for different outstanding owners.

Safe recovery sequence

  1. Freeze the failing request context and record 0xC80004B3, the Jet API name, and the current instance/session ownership.
  2. Verify the code-specific precondition: capture the canonical path, attachment list, working directory, case/normalization, and file existence.
  3. Apply the targeted fix: locate or attach the correct database instead of creating an empty replacement automatically.
  4. Before retrying the operation, reconcile attachment, open/closed state, file identity, and database header status.

Actions that can hide or worsen the problem

  • Do not create an empty database at the expected path as a substitute for the missing or damaged artifact.
  • Do not force detach or delete while owners and recovery state are unknown.

Technical references


Looking for a different code? Search another status or error code.