FLUSHDB | SugarDB (original) (raw)
Syntax
FLUSHDB
Module
generic
Categories
dangerous keyspace slow write
Description
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:
db, err := sugardb.NewSugarDB()
if err != nil {
log.Fatal(err)
}
db.Flush(0)
