xref: /redis-3.2.3/src/help.h (revision 44acd50a)
1 /* Automatically generated by utils/generate-command-help.rb, do not edit. */
2 
3 #ifndef __REDIS_HELP_H
4 #define __REDIS_HELP_H
5 
6 static char *commandGroups[] = {
7     "generic",
8     "string",
9     "list",
10     "set",
11     "sorted_set",
12     "hash",
13     "pubsub",
14     "transactions",
15     "connection",
16     "server",
17     "scripting",
18     "hyperloglog"
19 };
20 
21 struct commandHelp {
22   char *name;
23   char *params;
24   char *summary;
25   int group;
26   char *since;
27 } commandHelp[] = {
28     { "APPEND",
29     "key value",
30     "Append a value to a key",
31     1,
32     "2.0.0" },
33     { "AUTH",
34     "password",
35     "Authenticate to the server",
36     8,
37     "1.0.0" },
38     { "BGREWRITEAOF",
39     "-",
40     "Asynchronously rewrite the append-only file",
41     9,
42     "1.0.0" },
43     { "BGSAVE",
44     "-",
45     "Asynchronously save the dataset to disk",
46     9,
47     "1.0.0" },
48     { "BITCOUNT",
49     "key [start] [end]",
50     "Count set bits in a string",
51     1,
52     "2.6.0" },
53     { "BITOP",
54     "operation destkey key [key ...]",
55     "Perform bitwise operations between strings",
56     1,
57     "2.6.0" },
58     { "BITPOS",
59     "key bit [start] [end]",
60     "Find first bit set or clear in a string",
61     1,
62     "2.8.7" },
63     { "BLPOP",
64     "key [key ...] timeout",
65     "Remove and get the first element in a list, or block until one is available",
66     2,
67     "2.0.0" },
68     { "BRPOP",
69     "key [key ...] timeout",
70     "Remove and get the last element in a list, or block until one is available",
71     2,
72     "2.0.0" },
73     { "BRPOPLPUSH",
74     "source destination timeout",
75     "Pop a value from a list, push it to another list and return it; or block until one is available",
76     2,
77     "2.2.0" },
78     { "CLIENT GETNAME",
79     "-",
80     "Get the current connection name",
81     9,
82     "2.6.9" },
83     { "CLIENT KILL",
84     "ip:port",
85     "Kill the connection of a client",
86     9,
87     "2.4.0" },
88     { "CLIENT LIST",
89     "-",
90     "Get the list of client connections",
91     9,
92     "2.4.0" },
93     { "CLIENT PAUSE",
94     "timeout",
95     "Stop processing commands from clients for some time",
96     9,
97     "2.9.50" },
98     { "CLIENT SETNAME",
99     "connection-name",
100     "Set the current connection name",
101     9,
102     "2.6.9" },
103     { "CONFIG GET",
104     "parameter",
105     "Get the value of a configuration parameter",
106     9,
107     "2.0.0" },
108     { "CONFIG RESETSTAT",
109     "-",
110     "Reset the stats returned by INFO",
111     9,
112     "2.0.0" },
113     { "CONFIG REWRITE",
114     "-",
115     "Rewrite the configuration file with the in memory configuration",
116     9,
117     "2.8.0" },
118     { "CONFIG SET",
119     "parameter value",
120     "Set a configuration parameter to the given value",
121     9,
122     "2.0.0" },
123     { "DBSIZE",
124     "-",
125     "Return the number of keys in the selected database",
126     9,
127     "1.0.0" },
128     { "DEBUG OBJECT",
129     "key",
130     "Get debugging information about a key",
131     9,
132     "1.0.0" },
133     { "DEBUG SEGFAULT",
134     "-",
135     "Make the server crash",
136     9,
137     "1.0.0" },
138     { "DECR",
139     "key",
140     "Decrement the integer value of a key by one",
141     1,
142     "1.0.0" },
143     { "DECRBY",
144     "key decrement",
145     "Decrement the integer value of a key by the given number",
146     1,
147     "1.0.0" },
148     { "DEL",
149     "key [key ...]",
150     "Delete a key",
151     0,
152     "1.0.0" },
153     { "DISCARD",
154     "-",
155     "Discard all commands issued after MULTI",
156     7,
157     "2.0.0" },
158     { "DUMP",
159     "key",
160     "Return a serialized version of the value stored at the specified key.",
161     0,
162     "2.6.0" },
163     { "ECHO",
164     "message",
165     "Echo the given string",
166     8,
167     "1.0.0" },
168     { "EVAL",
169     "script numkeys key [key ...] arg [arg ...]",
170     "Execute a Lua script server side",
171     10,
172     "2.6.0" },
173     { "EVALSHA",
174     "sha1 numkeys key [key ...] arg [arg ...]",
175     "Execute a Lua script server side",
176     10,
177     "2.6.0" },
178     { "EXEC",
179     "-",
180     "Execute all commands issued after MULTI",
181     7,
182     "1.2.0" },
183     { "EXISTS",
184     "key",
185     "Determine if a key exists",
186     0,
187     "1.0.0" },
188     { "EXPIRE",
189     "key seconds",
190     "Set a key's time to live in seconds",
191     0,
192     "1.0.0" },
193     { "EXPIREAT",
194     "key timestamp",
195     "Set the expiration for a key as a UNIX timestamp",
196     0,
197     "1.2.0" },
198     { "FLUSHALL",
199     "-",
200     "Remove all keys from all databases",
201     9,
202     "1.0.0" },
203     { "FLUSHDB",
204     "-",
205     "Remove all keys from the current database",
206     9,
207     "1.0.0" },
208     { "GET",
209     "key",
210     "Get the value of a key",
211     1,
212     "1.0.0" },
213     { "GETBIT",
214     "key offset",
215     "Returns the bit value at offset in the string value stored at key",
216     1,
217     "2.2.0" },
218     { "GETRANGE",
219     "key start end",
220     "Get a substring of the string stored at a key",
221     1,
222     "2.4.0" },
223     { "GETSET",
224     "key value",
225     "Set the string value of a key and return its old value",
226     1,
227     "1.0.0" },
228     { "HDEL",
229     "key field [field ...]",
230     "Delete one or more hash fields",
231     5,
232     "2.0.0" },
233     { "HEXISTS",
234     "key field",
235     "Determine if a hash field exists",
236     5,
237     "2.0.0" },
238     { "HGET",
239     "key field",
240     "Get the value of a hash field",
241     5,
242     "2.0.0" },
243     { "HGETALL",
244     "key",
245     "Get all the fields and values in a hash",
246     5,
247     "2.0.0" },
248     { "HINCRBY",
249     "key field increment",
250     "Increment the integer value of a hash field by the given number",
251     5,
252     "2.0.0" },
253     { "HINCRBYFLOAT",
254     "key field increment",
255     "Increment the float value of a hash field by the given amount",
256     5,
257     "2.6.0" },
258     { "HKEYS",
259     "key",
260     "Get all the fields in a hash",
261     5,
262     "2.0.0" },
263     { "HLEN",
264     "key",
265     "Get the number of fields in a hash",
266     5,
267     "2.0.0" },
268     { "HMGET",
269     "key field [field ...]",
270     "Get the values of all the given hash fields",
271     5,
272     "2.0.0" },
273     { "HMSET",
274     "key field value [field value ...]",
275     "Set multiple hash fields to multiple values",
276     5,
277     "2.0.0" },
278     { "HSCAN",
279     "key cursor [MATCH pattern] [COUNT count]",
280     "Incrementally iterate hash fields and associated values",
281     5,
282     "2.8.0" },
283     { "HSET",
284     "key field value",
285     "Set the string value of a hash field",
286     5,
287     "2.0.0" },
288     { "HSETNX",
289     "key field value",
290     "Set the value of a hash field, only if the field does not exist",
291     5,
292     "2.0.0" },
293     { "HVALS",
294     "key",
295     "Get all the values in a hash",
296     5,
297     "2.0.0" },
298     { "INCR",
299     "key",
300     "Increment the integer value of a key by one",
301     1,
302     "1.0.0" },
303     { "INCRBY",
304     "key increment",
305     "Increment the integer value of a key by the given amount",
306     1,
307     "1.0.0" },
308     { "INCRBYFLOAT",
309     "key increment",
310     "Increment the float value of a key by the given amount",
311     1,
312     "2.6.0" },
313     { "INFO",
314     "[section]",
315     "Get information and statistics about the server",
316     9,
317     "1.0.0" },
318     { "KEYS",
319     "pattern",
320     "Find all keys matching the given pattern",
321     0,
322     "1.0.0" },
323     { "LASTSAVE",
324     "-",
325     "Get the UNIX time stamp of the last successful save to disk",
326     9,
327     "1.0.0" },
328     { "LINDEX",
329     "key index",
330     "Get an element from a list by its index",
331     2,
332     "1.0.0" },
333     { "LINSERT",
334     "key BEFORE|AFTER pivot value",
335     "Insert an element before or after another element in a list",
336     2,
337     "2.2.0" },
338     { "LLEN",
339     "key",
340     "Get the length of a list",
341     2,
342     "1.0.0" },
343     { "LPOP",
344     "key",
345     "Remove and get the first element in a list",
346     2,
347     "1.0.0" },
348     { "LPUSH",
349     "key value [value ...]",
350     "Prepend one or multiple values to a list",
351     2,
352     "1.0.0" },
353     { "LPUSHX",
354     "key value",
355     "Prepend a value to a list, only if the list exists",
356     2,
357     "2.2.0" },
358     { "LRANGE",
359     "key start stop",
360     "Get a range of elements from a list",
361     2,
362     "1.0.0" },
363     { "LREM",
364     "key count value",
365     "Remove elements from a list",
366     2,
367     "1.0.0" },
368     { "LSET",
369     "key index value",
370     "Set the value of an element in a list by its index",
371     2,
372     "1.0.0" },
373     { "LTRIM",
374     "key start stop",
375     "Trim a list to the specified range",
376     2,
377     "1.0.0" },
378     { "MGET",
379     "key [key ...]",
380     "Get the values of all the given keys",
381     1,
382     "1.0.0" },
383     { "MIGRATE",
384     "host port key destination-db timeout [COPY] [REPLACE]",
385     "Atomically transfer a key from a Redis instance to another one.",
386     0,
387     "2.6.0" },
388     { "MONITOR",
389     "-",
390     "Listen for all requests received by the server in real time",
391     9,
392     "1.0.0" },
393     { "MOVE",
394     "key db",
395     "Move a key to another database",
396     0,
397     "1.0.0" },
398     { "MSET",
399     "key value [key value ...]",
400     "Set multiple keys to multiple values",
401     1,
402     "1.0.1" },
403     { "MSETNX",
404     "key value [key value ...]",
405     "Set multiple keys to multiple values, only if none of the keys exist",
406     1,
407     "1.0.1" },
408     { "MULTI",
409     "-",
410     "Mark the start of a transaction block",
411     7,
412     "1.2.0" },
413     { "OBJECT",
414     "subcommand [arguments [arguments ...]]",
415     "Inspect the internals of Redis objects",
416     0,
417     "2.2.3" },
418     { "PERSIST",
419     "key",
420     "Remove the expiration from a key",
421     0,
422     "2.2.0" },
423     { "PEXPIRE",
424     "key milliseconds",
425     "Set a key's time to live in milliseconds",
426     0,
427     "2.6.0" },
428     { "PEXPIREAT",
429     "key milliseconds-timestamp",
430     "Set the expiration for a key as a UNIX timestamp specified in milliseconds",
431     0,
432     "2.6.0" },
433     { "PFADD",
434     "key element [element ...]",
435     "Adds the specified elements to the specified HyperLogLog.",
436     11,
437     "2.8.9" },
438     { "PFCOUNT",
439     "key [key ...]",
440     "Return the approximated cardinality of the set(s) observed by the HyperLogLog at key(s).",
441     11,
442     "2.8.9" },
443     { "PFMERGE",
444     "destkey sourcekey [sourcekey ...]",
445     "Merge N different HyperLogLogs into a single one.",
446     11,
447     "2.8.9" },
448     { "PING",
449     "-",
450     "Ping the server",
451     8,
452     "1.0.0" },
453     { "PSETEX",
454     "key milliseconds value",
455     "Set the value and expiration in milliseconds of a key",
456     1,
457     "2.6.0" },
458     { "PSUBSCRIBE",
459     "pattern [pattern ...]",
460     "Listen for messages published to channels matching the given patterns",
461     6,
462     "2.0.0" },
463     { "PTTL",
464     "key",
465     "Get the time to live for a key in milliseconds",
466     0,
467     "2.6.0" },
468     { "PUBLISH",
469     "channel message",
470     "Post a message to a channel",
471     6,
472     "2.0.0" },
473     { "PUBSUB",
474     "subcommand [argument [argument ...]]",
475     "Inspect the state of the Pub/Sub subsystem",
476     6,
477     "2.8.0" },
478     { "PUNSUBSCRIBE",
479     "[pattern [pattern ...]]",
480     "Stop listening for messages posted to channels matching the given patterns",
481     6,
482     "2.0.0" },
483     { "QUIT",
484     "-",
485     "Close the connection",
486     8,
487     "1.0.0" },
488     { "RANDOMKEY",
489     "-",
490     "Return a random key from the keyspace",
491     0,
492     "1.0.0" },
493     { "RENAME",
494     "key newkey",
495     "Rename a key",
496     0,
497     "1.0.0" },
498     { "RENAMENX",
499     "key newkey",
500     "Rename a key, only if the new key does not exist",
501     0,
502     "1.0.0" },
503     { "RESTORE",
504     "key ttl serialized-value",
505     "Create a key using the provided serialized value, previously obtained using DUMP.",
506     0,
507     "2.6.0" },
508     { "RPOP",
509     "key",
510     "Remove and get the last element in a list",
511     2,
512     "1.0.0" },
513     { "RPOPLPUSH",
514     "source destination",
515     "Remove the last element in a list, append it to another list and return it",
516     2,
517     "1.2.0" },
518     { "RPUSH",
519     "key value [value ...]",
520     "Append one or multiple values to a list",
521     2,
522     "1.0.0" },
523     { "RPUSHX",
524     "key value",
525     "Append a value to a list, only if the list exists",
526     2,
527     "2.2.0" },
528     { "SADD",
529     "key member [member ...]",
530     "Add one or more members to a set",
531     3,
532     "1.0.0" },
533     { "SAVE",
534     "-",
535     "Synchronously save the dataset to disk",
536     9,
537     "1.0.0" },
538     { "SCAN",
539     "cursor [MATCH pattern] [COUNT count]",
540     "Incrementally iterate the keys space",
541     0,
542     "2.8.0" },
543     { "SCARD",
544     "key",
545     "Get the number of members in a set",
546     3,
547     "1.0.0" },
548     { "SCRIPT EXISTS",
549     "script [script ...]",
550     "Check existence of scripts in the script cache.",
551     10,
552     "2.6.0" },
553     { "SCRIPT FLUSH",
554     "-",
555     "Remove all the scripts from the script cache.",
556     10,
557     "2.6.0" },
558     { "SCRIPT KILL",
559     "-",
560     "Kill the script currently in execution.",
561     10,
562     "2.6.0" },
563     { "SCRIPT LOAD",
564     "script",
565     "Load the specified Lua script into the script cache.",
566     10,
567     "2.6.0" },
568     { "SDIFF",
569     "key [key ...]",
570     "Subtract multiple sets",
571     3,
572     "1.0.0" },
573     { "SDIFFSTORE",
574     "destination key [key ...]",
575     "Subtract multiple sets and store the resulting set in a key",
576     3,
577     "1.0.0" },
578     { "SELECT",
579     "index",
580     "Change the selected database for the current connection",
581     8,
582     "1.0.0" },
583     { "SET",
584     "key value [EX seconds] [PX milliseconds] [NX|XX]",
585     "Set the string value of a key",
586     1,
587     "1.0.0" },
588     { "SETBIT",
589     "key offset value",
590     "Sets or clears the bit at offset in the string value stored at key",
591     1,
592     "2.2.0" },
593     { "SETEX",
594     "key seconds value",
595     "Set the value and expiration of a key",
596     1,
597     "2.0.0" },
598     { "SETNX",
599     "key value",
600     "Set the value of a key, only if the key does not exist",
601     1,
602     "1.0.0" },
603     { "SETRANGE",
604     "key offset value",
605     "Overwrite part of a string at key starting at the specified offset",
606     1,
607     "2.2.0" },
608     { "SHUTDOWN",
609     "[NOSAVE] [SAVE]",
610     "Synchronously save the dataset to disk and then shut down the server",
611     9,
612     "1.0.0" },
613     { "SINTER",
614     "key [key ...]",
615     "Intersect multiple sets",
616     3,
617     "1.0.0" },
618     { "SINTERSTORE",
619     "destination key [key ...]",
620     "Intersect multiple sets and store the resulting set in a key",
621     3,
622     "1.0.0" },
623     { "SISMEMBER",
624     "key member",
625     "Determine if a given value is a member of a set",
626     3,
627     "1.0.0" },
628     { "SLAVEOF",
629     "host port",
630     "Make the server a slave of another instance, or promote it as master",
631     9,
632     "1.0.0" },
633     { "SLOWLOG",
634     "subcommand [argument]",
635     "Manages the Redis slow queries log",
636     9,
637     "2.2.12" },
638     { "SMEMBERS",
639     "key",
640     "Get all the members in a set",
641     3,
642     "1.0.0" },
643     { "SMOVE",
644     "source destination member",
645     "Move a member from one set to another",
646     3,
647     "1.0.0" },
648     { "SORT",
649     "key [BY pattern] [LIMIT offset count] [GET pattern [GET pattern ...]] [ASC|DESC] [ALPHA] [STORE destination]",
650     "Sort the elements in a list, set or sorted set",
651     0,
652     "1.0.0" },
653     { "SPOP",
654     "key",
655     "Remove and return a random member from a set",
656     3,
657     "1.0.0" },
658     { "SRANDMEMBER",
659     "key [count]",
660     "Get one or multiple random members from a set",
661     3,
662     "1.0.0" },
663     { "SREM",
664     "key member [member ...]",
665     "Remove one or more members from a set",
666     3,
667     "1.0.0" },
668     { "SSCAN",
669     "key cursor [MATCH pattern] [COUNT count]",
670     "Incrementally iterate Set elements",
671     3,
672     "2.8.0" },
673     { "STRLEN",
674     "key",
675     "Get the length of the value stored in a key",
676     1,
677     "2.2.0" },
678     { "SUBSCRIBE",
679     "channel [channel ...]",
680     "Listen for messages published to the given channels",
681     6,
682     "2.0.0" },
683     { "SUNION",
684     "key [key ...]",
685     "Add multiple sets",
686     3,
687     "1.0.0" },
688     { "SUNIONSTORE",
689     "destination key [key ...]",
690     "Add multiple sets and store the resulting set in a key",
691     3,
692     "1.0.0" },
693     { "SYNC",
694     "-",
695     "Internal command used for replication",
696     9,
697     "1.0.0" },
698     { "TIME",
699     "-",
700     "Return the current server time",
701     9,
702     "2.6.0" },
703     { "TTL",
704     "key",
705     "Get the time to live for a key",
706     0,
707     "1.0.0" },
708     { "TYPE",
709     "key",
710     "Determine the type stored at key",
711     0,
712     "1.0.0" },
713     { "UNSUBSCRIBE",
714     "[channel [channel ...]]",
715     "Stop listening for messages posted to the given channels",
716     6,
717     "2.0.0" },
718     { "UNWATCH",
719     "-",
720     "Forget about all watched keys",
721     7,
722     "2.2.0" },
723     { "WATCH",
724     "key [key ...]",
725     "Watch the given keys to determine execution of the MULTI/EXEC block",
726     7,
727     "2.2.0" },
728     { "ZADD",
729     "key score member [score member ...]",
730     "Add one or more members to a sorted set, or update its score if it already exists",
731     4,
732     "1.2.0" },
733     { "ZCARD",
734     "key",
735     "Get the number of members in a sorted set",
736     4,
737     "1.2.0" },
738     { "ZCOUNT",
739     "key min max",
740     "Count the members in a sorted set with scores within the given values",
741     4,
742     "2.0.0" },
743     { "ZINCRBY",
744     "key increment member",
745     "Increment the score of a member in a sorted set",
746     4,
747     "1.2.0" },
748     { "ZINTERSTORE",
749     "destination numkeys key [key ...] [WEIGHTS weight] [AGGREGATE SUM|MIN|MAX]",
750     "Intersect multiple sorted sets and store the resulting sorted set in a new key",
751     4,
752     "2.0.0" },
753     { "ZLEXCOUNT",
754     "key min max",
755     "Count the number of members in a sorted set between a given lexicographical range",
756     4,
757     "2.8.9" },
758     { "ZRANGE",
759     "key start stop [WITHSCORES]",
760     "Return a range of members in a sorted set, by index",
761     4,
762     "1.2.0" },
763     { "ZRANGEBYLEX",
764     "key min max [LIMIT offset count]",
765     "Return a range of members in a sorted set, by lexicographical range",
766     4,
767     "2.8.9" },
768     { "ZRANGEBYSCORE",
769     "key min max [WITHSCORES] [LIMIT offset count]",
770     "Return a range of members in a sorted set, by score",
771     4,
772     "1.0.5" },
773     { "ZRANK",
774     "key member",
775     "Determine the index of a member in a sorted set",
776     4,
777     "2.0.0" },
778     { "ZREM",
779     "key member [member ...]",
780     "Remove one or more members from a sorted set",
781     4,
782     "1.2.0" },
783     { "ZREMRANGEBYLEX",
784     "key min max",
785     "Remove all members in a sorted set between the given lexicographical range",
786     4,
787     "2.8.9" },
788     { "ZREMRANGEBYRANK",
789     "key start stop",
790     "Remove all members in a sorted set within the given indexes",
791     4,
792     "2.0.0" },
793     { "ZREMRANGEBYSCORE",
794     "key min max",
795     "Remove all members in a sorted set within the given scores",
796     4,
797     "1.2.0" },
798     { "ZREVRANGE",
799     "key start stop [WITHSCORES]",
800     "Return a range of members in a sorted set, by index, with scores ordered from high to low",
801     4,
802     "1.2.0" },
803     { "ZREVRANGEBYSCORE",
804     "key max min [WITHSCORES] [LIMIT offset count]",
805     "Return a range of members in a sorted set, by score, with scores ordered from high to low",
806     4,
807     "2.2.0" },
808     { "ZREVRANK",
809     "key member",
810     "Determine the index of a member in a sorted set, with scores ordered from high to low",
811     4,
812     "2.0.0" },
813     { "ZSCAN",
814     "key cursor [MATCH pattern] [COUNT count]",
815     "Incrementally iterate sorted sets elements and associated scores",
816     4,
817     "2.8.0" },
818     { "ZSCORE",
819     "key member",
820     "Get the score associated with the given member in a sorted set",
821     4,
822     "1.2.0" },
823     { "ZUNIONSTORE",
824     "destination numkeys key [key ...] [WEIGHTS weight] [AGGREGATE SUM|MIN|MAX]",
825     "Add multiple sorted sets and store the resulting sorted set in a new key",
826     4,
827     "2.0.0" }
828 };
829 
830 #endif
831