DUMP

Apply for Redis Developer Course Redis Regular Inspection / Technical Support Redis Enterprise Server

Dump the data

Simple usage is dump key.
Returns the value in a Redis-specific format. You can restore it to the DB with the RESTORE command.
Dump data does not include expire time. You can set expire time when using RESTORE.

Example

Command>set key a
Result>OK
Command>dump key
Result>"\x00\x01a\x06\x00)\x13\x87\x1bzcA'"
Command>del key
Result>1
Command>restore key 0 "\x00\x01a\x06\x00)\x13\x87\x1bzcA'"
Result>OK
Command>get key
Result>a


Syntax

DUMP key

  • Available since version 2.6.0.
  • Time complexity is O(1).
Related commands RESTORE, MIGRATE
Clients for Java Jedis, Lettuce, Redisson
Clients for C Hiredis

<< MOVE DUMP RESTORE >>

Email 답글이 올라오면 이메일로 알려드리겠습니다.