Skip to content

Instantly share code, notes, and snippets.

@ktkaushik
Created June 25, 2015 12:09
Show Gist options
  • Save ktkaushik/812071045dd43d5f8f94 to your computer and use it in GitHub Desktop.
Save ktkaushik/812071045dd43d5f8f94 to your computer and use it in GitHub Desktop.
LUA Eval script to Delete/Expire multiple keys in Redis
EVAL "for i, name in ipairs(redis.call('KEYS', 'author_*')) do redis.call('expire', name, 0); end" 0
@Rajat-Goyal
Copy link

I am trying to delete multiple keys and not keys matching any particular pattern

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment