P
P
pup_pupets2016-08-27 15:30:27
Redis
pup_pupets, 2016-08-27 15:30:27

How to get and remove keys from Redis in bulk?

The data is stored in this form:

ключ: xxxx:a, значение: ddd
ключ: xxxx:b, значение: eee
ключ: xxxx:c, значение: uuu

I would like to get all values ​​by key xxx:and then delete those values.
Through keys *I certainly get all the keys. But now it turns out that I need to do for each keyget , and then for each del . Is it possible to minimize this to a minimum of commands?

Answer the question

In order to leave comments, you need to log in

1 answer(s)
P
pup_pupets, 2016-08-27
@pup_pupets

I decided. Collected keys in a bunch and sent them to DEL
Received data via MGET(<key bunch>)

Didn't find what you were looking for?

Ask your question

Ask a Question

731 491 924 answers to any question