Home > Database > Redis > body text

Is redis a relational database?

(*-*)浩
Release: 2019-06-18 11:02:00
Original
11833 people have browsed it

Redis is a key-value nosql database (non-relational database). Value types that support storage include string (string), list (linked list), set (set), zset (sorted set - ordered set) and hash (hash type). These data types support push/pop, add/remove, intersection, union, difference, and richer operations, and these operations are all atomic. To ensure efficiency, data is cached in memory.

Is redis a relational database?

NoSQL non-relational databases mainly refer to those non-relational, distributed data storage systems that generally do not guarantee ACID, mainly representing MongoDB. Redis, CouchDB. (Recommended learning: Redis video tutorial)

NoSQL proposes another concept, which is stored by key value, and the structure is unstable. Each tuple can have different values. The same fields will not be limited to a fixed structure, which can reduce some time and space overhead. Using this method, in order to obtain different information about the user, there is no need to perform multi-table queries like in a relational database. You only need to retrieve the corresponding value based on the key.

Key-value database for high-performance concurrent reading and writing

The main feature is extremely high concurrent reading and writing performance, such as Redis.

NoSql is suitable for storing unstructured data, such as articles and comments:

(1) These data are usually used for fuzzy processing, such as full-text search and machine learning, and are suitable for storage Simple data.

(2) These data are massive, and the growth rate is unpredictable.

(3) Obtaining data by key is very efficient, but the support for joins or other structured queries is relatively poor.

NoSql expands horizontally, and non-relational databases are naturally distributed, so load balancing can be achieved through clusters.

Non-relational is a flat data collection. Data can often be repeated. A single database is rarely separated, but is stored as a whole. This kind of whole block reading data is more efficient.

SQL databases are still powerful and can process transactions reliably and maintain transaction integrity. Only consider NoSql databases when your data is very large and operation expansion requires a more distributed system.

For more Redis-related technical articles, please visit the Introduction to Using Redis Database Tutorial column to learn!

The above is the detailed content of Is redis a relational database?. For more information, please follow other related articles on the PHP Chinese website!

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template
About us Disclaimer Sitemap
php.cn:Public welfare online PHP training,Help PHP learners grow quickly!