Description
Description | S.NO | Command | Description |
|---|---|---|
| 1 | Dump key | This command returns a serialized version of the esteem stored at the predefined key. |
| 2 | Delete key | This command deletes the key, if exists |
| 3 | Exists | This command checks whether the key exists or not. |
| 4 | Expireat key timestamp | Expires the key after the specified time. Here time is in Unix timestamp format |
| 5 | Expire key | Expires the key after the specified time |
| 6 | Pexpireat key milliseconds-timestamp | Set the expiry ofkey in unix timestamp specified as milliseconds |
| 7 | Pexpire key milliseconds | Set the expiry of key in millseconds |
| 8 | Keys pattern | Finds all the keys matching the specified pattern |
| 9 | Persist key | Remove the expiration from the key |
| 10 | Pttl keys | Get the remaining time in keys expiry in milliseconds |
| 11 | TTL key | Get the remaining time in keys expiry |
| 12 | Randdomkey | Return a random key from redis |
| 13 | Rename key newkey | Change the key name |
Syntax
Examples
Key Points