RenameCommand: Contents
  RENAME _oldkey_ _newkey_
    Return value
    See also

RenameCommand

RENAME _oldkey_ _newkey_

Time complexity: O(1)
Atomically renames the key oldkey to newkey. If the source anddestination name are the same an error is returned. If newkeyalready exists it is overwritten.

Return value

Status code repy

See also

  • RENAMENX if you don't want overwrite the destionation key if it exists.