Redis – Keys Redis keys commands are used for managing keys in Redis. Following is the syntax for using redis keys commands. Syntax redis 127.0.0.1:6379> COMMAND KEY_NAME Example redis 127.0.0.1:6379> SET tutorialspoint redis OK redis 127.0.0.1:6379> DEL tutorialspoint (integer) 1 In the above example, DEL is the command, while tutorialspoint is the key. If the […]
Category Archives: redis
Redis – Backup Redis SAVE command is used to create a backup of the current Redis database. Syntax Following is the basic syntax of redis SAVE command. 127.0.0.1:6379> SAVE Example Following example creates a backup of the current database. 127.0.0.1:6379> SAVE OK This command will create a dump.rdb file in your Redis directory. Restore Redis […]
Redis – Lists Redis Lists are simply lists of strings, sorted by insertion order. You can add elements in Redis lists in the head or the tail of the list. Maximum length of a list is 232 – 1 elements (4294967295, more than 4 billion of elements per list). Example redis 127.0.0.1:6379> LPUSH tutorials redis […]