Skip to content

CLI

Refresh a database

dbcode introspect makes the editor reload what it knows about a database, the same as Refresh on that database in the explorer. Use it after a migration or a script has changed the structure and you want the explorer, completions and dbcode open to see the result.

Terminal window
dbcode introspect -c prod
dbcode introspect -c prod --database reporting
dbcode introspect -c prod --schema sales
  • -c names a saved connection, by name or id. Any saved connection works.
  • Without --database, the connection’s default database is refreshed.
  • --schema refreshes one schema instead of the whole database, which is quicker on large databases. On a database without schemas the editor says so.
  • --app, --profile and --workspace pick the editor and settings, as for dbcode query.

The editor opens if it is not running and shows a message if the connection cannot be reached. Nothing is printed on success. A full refresh reads the whole structure, so on a large database it can take a while.