DEL
AttentionThis page documents an earlier version. Go to the latest (v2.1)version.
Early Releases: Single-key request only. Requests with multiple keys are not yet supported.
Synopsis
DEL key
This command deletes the given key
.
- If the
key
does not exist, it is ignored and not counted toward the total number of removed keys.
Return Value
Returns number of keys that were removed.
Examples
You can do this as shown below.
$ SET yuga1 "America"
"OK"
$ SET yuga2 "Africa"
"OK"
$ DEL yuga1
1
$ DEL not_a_key
0
$ DEL yuga1 yuga2
"ERR del: Wrong number of arguments"
See Also
exists
, flushall
, flushdb
, get
, getrange
, hdel
, hexists
, hget
, hset
, hincrby
, sadd
, set
当前内容版权归 YugabyteDB 或其关联方所有,如需对内容或内容相关联开源项目进行关注与资助,请访问 YugabyteDB .