ruby - Dumping all key/value pairs in a Redis db -


I am using an ORM named Ruby which works on top of radis and is eager to know That's how data is actually stored. I was thinking that Lalis is a way to list all keys / values ​​in DB.

Any lead will help me a lot (I basically stuck at the ATM). thank you in advanced!

Update:
A note for others trying to use Radisson-CLI, use this:

  $ Redis -CL key * (after press * Ctrl-D) ... (a list of keys is printed out and exits) $  

Thanks @ Letrez and @hellvinz!

Redis dataset by using the redis-cli tool included in redis distribution Can detect.

Just start the device without arguments, then type the command to explore the dataset.

For example key will list all the keys matching a globe-style pattern with the example: keys * shows all available keys to you Will give.

Then you can use the TYPE command to specify how the given key is, if it is a list then you LRANGE mykey 0 - You can retrieve the elements within 1 . If this is a set, you will use SMEMBERS mykey and beyond instead. Check out the Redis documentation for a list of all the available commands and how they work.


Comments