getSchemaView Method @beta
Get the schema view for this iModel. The view is built lazily on
first call by fetching compact binary schema data via PRAGMA schema_view through
the ConcurrentQuery thread pool. Subsequent calls return the cached view. Multiple
concurrent callers share a single in-flight build.
The returned SchemaView is a lightweight, read-only, synchronous API for
navigating schema metadata - classes, properties, relationships, enumerations, etc.
It is the recommended default for runtime read-only metadata access and is significantly
faster and lower-memory than schemaContext. Use schemaContext for schema authoring,
custom-attribute deserialization, or anywhere you need the full ecschema-metadata object graph.
getSchemaView(): Promise<SchemaView>
Returns - Promise<SchemaView>
Defined in
- backend/src/IModelDb.ts Line 1741
Last Updated: 27 May, 2026