Skip to content

Methods

use_defaults

Selects the namespace and database set by DEFINE CONFIG DEFAULT. If no default is configured, the session is left unchanged.

Method Syntax
db.use_defaults().await?

This complements use_ns() and use_db() when you want the configured default instead of a specific pair.

The defaults only fill in what is missing. A session that has already selected a namespace - from a token, for example - keeps that selection.

Was this page helpful?