HGETALL

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

Get all fields and values of a key

The usage is hgetall key.

Example

Command>hgetall user-1
Result> 1) email
2) charlie@redisgate.com
3) language
4) English
5) gender
6) M
Command>hgetall user-2
Result> 1) gender
2) F
3) name
4) Sally
5) language
6) Korean

View animation



Syntax

HGETALL key [key ...]

  • Available since version 2.0.0.
  • Time complexity is O(N). N is the number of fields.
SQL Select If you are on Redis Enterprise 7.3.0 or later, try SELECT.
Clients for Java Jedis, Lettuce, Redisson
Clients for C Hiredis

<< HVALS HGETALL HLS >>

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