Redis data structure and commands

Source: Internet
Author: User

Redis is a key-value database; For redis, key is a string type, and value is only a binary string, redis does not care about its content;

Using different commands, redis decides to store values in a specific data structure;

For example, if you use the set command, the value will exist in the string; if you use hset, the value will exist in the set.

First, list the items to be analyzed and supplemented.

1. String

Mainly supports set append strlen getrange incr setbit and other commands

2. Hash

Mainly supports hset hmset and other commands

3. List

Mainly supports lpush

4. Set

Stores different values and supports commands such as sadd ismember sinter.

5 sorted set

Supports zadd zcount and other commands

Related Article

Contact Us

The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion; products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the content of the page makes you feel confusing, please write us an email, we will handle the problem within 5 days after receiving your email.

If you find any instances of plagiarism from the community, please send an email to: info-contact@alibabacloud.com and provide relevant evidence. A staff member will contact you within 5 working days.

A Free Trial That Lets You Build Big!

Start building with 50+ products and up to 12 months usage for Elastic Compute Service

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.