FLUSHDB
Syntax
FLUSHDB
Module
genericCategories
dangerous keyspace slow writeDescription
Delete all the keys in the currently selected database. This command is always synchronous.
Examples
- Go (Embedded)
- CLI
For the embedded instance, you need to pass the database index to the Flush
method:
vault, err := echovault.NewEchoVault()
if err != nil {
log.Fatal(err)
}
vault.Flush(0)
Flush the database that the current connection is operating from:
FLUSHDB