ZPOPMIN
Syntax
ZPOPMIN key [count]
Module
sortedsetCategories
write slow sortedsetDescription
Removes and returns 'count' number of members in the sorted set with the lowest scores. Default count is 1.
Examples
- Go (Embedded)
- CLI
Remove and return 'count' number of members in the sorted set with the lowest scores:
db, err := sugardb.NewSugarDB()
if err != nil {
log.Fatal(err)
}
members, err := db.ZPopMin("key", 2)
Remove and return 'count' number of members in the sorted set with the lowest scores:
> ZPOPMIN key 2