Difference between revisions of "Redis-cli"

From wikieduonline
Jump to navigation Jump to search
Line 38: Line 38:
  
  
  redis-cli help
+
  [[redis-cli help]]
redis-cli 7.0.4
+
 
To get help about Redis commands type:
 
      "help @<group>" to get a list of commands in <group>
 
      "help <command>" for help on <command>
 
      "help <tab>" to get a list of possible help topics
 
      "quit" to exit
 
 
To set redis-cli preferences:
 
      ":set hints" enable online hints
 
      ":set nohints" disable online hints
 
Set your preferences in ~/.redisclirc
 
  
 
== Related ==
 
== Related ==

Revision as of 15:42, 18 September 2022

redis-cli --help
redis-cli INFO SERVER
redis-cli DBSIZE
(integer) 0
redis-cli LPUSH mylist a b c d
(integer) 4
redis-cli --csv LRANGE mylist 0 -1
"d","c","b","a"
redis-cli INCR mycounter
(integer) 1
redis-cli INCR mycounter
(integer) 2
redis-cli --raw INCR mycounter
3
redis-cli PING or redis-cli ping
PONG
redis-cli FLUSHALL
OK
 redis-cli -x SET net_services < /etc/services


--bigkeys


redis-cli
Could not connect to Redis at 127.0.0.1:6379: Connection refused

Solution: brew install redis && brew services restart redis


redis-cli help


Related

See also

Advertising: