ConnectionsMaintain
Schema loading and caching
DBCode introspects your database schema to populate the explorer tree with tables, views, columns, indexes, and other objects. For large databases with thousands of objects, this can take time. The schema loading settings let you optimize this process.
Progressive Loading
Section titled “Progressive Loading”Progressive loading changes how DBCode fetches schema information. New connections use it by default; existing connections keep their setting.
- Standard mode: Fetches all schema details (columns, indexes, keys) upfront when connecting
- Progressive mode: Fetches only object names initially, then loads details on-demand as you expand items
This can significantly reduce initial connection time for large databases.
When to Use Progressive Loading
Section titled “When to Use Progressive Loading”Progressive loading is beneficial when:
- Your database has hundreds or thousands of tables/views
- Initial connection takes several seconds or longer
- You typically work with a small subset of tables
- You’re connecting over a slow network
Turning Progressive Loading on or off
Section titled “Turning Progressive Loading on or off”- Open the connection settings (right-click connection → Edit)
- Select Introspection
- Turn Progressive Loading on or off
While it is on, additional options become available:
Settings
Section titled “Settings”Prefetch Details
Section titled “Prefetch Details”When enabled, DBCode fetches full schema details in the background after the initial connection completes. It is off by default when you create a connection. This gives you fast initial load times while still populating the full schema for features like autocomplete.
- Enabled: Best of both worlds - fast connection, full schema eventually
- Disabled: Only fetch details when you explicitly expand items
Batch Size
Section titled “Batch Size”Controls how many objects are fetched per request when loading details. Higher values mean fewer requests but larger payloads.
- Default: 15-50 depending on database type
- Lower values: Better for slow connections or rate-limited APIs
- Higher values: Better for fast connections with many objects
Cache TTL
Section titled “Cache TTL”How long (in days) cached schema details remain valid before being refreshed.
- Default: 7 days
- Lower values: More frequent refreshes, always up-to-date
- Higher values: Less network traffic, faster subsequent connections
The cache is stored locally and survives VS Code restarts. Use the Refresh command on a connection to force a cache refresh.
Supported Databases
Section titled “Supported Databases”Progressive loading is available for every supported database. Some databases always use it.
- If you notice stale schema information, right-click the connection and select Refresh
- The cache is per-connection, so each connection maintains its own cached schema
- Disabling prefetch reduces background network activity but may slow down autocomplete until objects are expanded