Skip to main content

HDEL

Syntax

HDEL key field [field ...]

Module

hash

Categories

fast hash write

Description

Deletes the specified fields from the hash.

Examples

Delete fields from a hash:

db, err := sugardb.NewSugarDB()
if err != nil {
log.Fatal(err)
}
deletedCount, err := db.HDel("key", "field1", "field2")