$ keys * $ rename oldkey newkey $ renamex oldkey newkey new key exists thrown exception $ dbsize $ expire key time (seconds) $ TTL key return expiration time remaining number of seconds-2 A value that indicates that the key does not exist or has not been set for the remaining number of seconds $ select 0-15 defaults to 16 dictinary $ move Key Db-index $ flushdb clears all keys for the current library $ flushall clears all keys for all libraries $ setnx K EY value key exists to return 0, and does not change the original value; the value of $ getset key value is stored back key corresponding value, does not exist set value $ mget key1 key2 One returns multivalued list $ mset key value key Valu E is set multiple at a time, but does not overwrite the value of the key that already exists. $ incr key to key each add 1, does not exist then the first time for 1 $ decr key to key each plus 1, does not exist then the first time for-1 $ incrby Key IntegerValue increase the specified The value of $ Decrby key IntegerValue decreases by the specified value of $ append key value after the increment of the specified length value of $ substr key start end returns the key value of startindex (starting from 0), to Endi The value of the ndex (including the end index) does not change the original value corresponding to the key $lpush key value $rpush key value $llen $lrange key start end starts from 0 and end is negative to start from the back $ltr The IM key start end intercepts elements $lset key index value $lrem key count value removes count and value values from the key list, and count is 0 o'clock to delete all elements $lpop $rpop $ Blpop key1 key2 ... keyn timeout left-to-right scan returns a pair of first non-empty list for Lpop operation (also the return value), if all the list is empty or does not exist, then block timeout seconds, 0 for blocking $brpop Key1 key2 ... keyn timeout
Redis command string