Syntax
Parameters
The name of the key to delete.
Return value
Returns1 if the key was found and deleted, or (nil) if the key did not exist.
Errors
| Condition | Error message |
|---|---|
| Wrong number of arguments | (error) wrong number of arguments for 'DEL' |
Examples
Notes
Deletion is immediately appended to the AOF, so the removal is persisted before the command returns.
DEL only accepts a single key. To delete multiple keys, issue one DEL command per key.