-
Notifications
You must be signed in to change notification settings - Fork 1.1k
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
t push origin masterMerge branch 'rename'
- Loading branch information
Showing
4 changed files
with
133 additions
and
2 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
--- | ||
title: PSETEX | ||
linkTitle: PSETEX | ||
description: PSETEX | ||
menu: | ||
latest: | ||
parent: api-redis | ||
weight: 2272 | ||
aliases: | ||
- /latest/api/redis/psetex | ||
- /latest/api/yedis/psetex | ||
isTocNested: true | ||
showAsideToc: true | ||
--- | ||
|
||
## Synopsis | ||
<b>`PSETEX key ttl_in_msec string_value`</b><br> | ||
This command sets the value of `key` to be `string_value`, and sets the key to expire in `ttl_in_msec` milli-seconds. | ||
|
||
## Return Value | ||
Returns status string. | ||
|
||
## Examples | ||
|
||
```sh | ||
$ PSETEX yugakey 1000 "YugaByte" | ||
``` | ||
|
||
``` | ||
"OK" | ||
``` | ||
|
||
```sh | ||
$ GET yugakey | ||
``` | ||
|
||
``` | ||
"YugaByte" | ||
``` | ||
```sh | ||
$ PTTL yugakey | ||
``` | ||
|
||
``` | ||
(integer) 900 | ||
``` | ||
|
||
## See Also | ||
[`append`](../append/), [`set`](../set/), [`setex`](../setex/), [`get`](../get/), [`getrange`](../getrange/), [`getset`](../getset/), [`incr`](../incr/), [`incrby`](../incrby/), [`setrange`](../setrange/), [`strlen`](../strlen/) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,30 @@ | ||
--- | ||
title: RENAME | ||
linkTitle: RENAME | ||
description: RENAME | ||
menu: | ||
latest: | ||
parent: api-redis | ||
weight: 2265 | ||
aliases: | ||
- /latest/api/redis/rename | ||
- /latest/api/yedis/rename | ||
isTocNested: true | ||
showAsideToc: true | ||
--- | ||
|
||
## Synopsis | ||
<b>`RENAME key1 key2`</b><br> | ||
Limited support: RENAME command is useful to rename one key as another key. | ||
This is currently a best-effort mechanism and is intended to only work when there is | ||
no concurrent updates to either the source or the destination keys. The TTL setting | ||
for the key itself is copied over to the destination key. However, for container | ||
types such as the TimeSeries type, the ttl settings for the sub-keys are not copied. | ||
|
||
## Return Value | ||
Returns status string. | ||
## See Also | ||
[`set`](../set/), | ||
[`get`](../get/), | ||
[`hset`](../hset/), | ||
[`hget`](../hget/), |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,49 @@ | ||
--- | ||
title: SETEX | ||
linkTitle: SETEX | ||
description: SETEX | ||
menu: | ||
latest: | ||
parent: api-redis | ||
weight: 2271 | ||
aliases: | ||
- /latest/api/redis/setex | ||
- /latest/api/yedis/setex | ||
isTocNested: true | ||
showAsideToc: true | ||
--- | ||
|
||
## Synopsis | ||
<b>`SETEX key ttl_in_sec string_value`</b><br> | ||
This command sets the value of `key` to be `string_value`, and sets the key to expire in `ttl_in_sec` seconds. | ||
|
||
## Return Value | ||
Returns status string. | ||
|
||
## Examples | ||
|
||
```sh | ||
$ SETEX yugakey 10 "YugaByte" | ||
``` | ||
|
||
``` | ||
"OK" | ||
``` | ||
|
||
```sh | ||
$ GET yugakey | ||
``` | ||
|
||
``` | ||
"YugaByte" | ||
``` | ||
```sh | ||
$ TTL yugakey | ||
``` | ||
|
||
``` | ||
(integer) 10 | ||
``` | ||
|
||
## See Also | ||
[`append`](../append/), [`set`](../set/), [`psetex`](../psetex/), [`get`](../get/), [`getrange`](../getrange/), [`getset`](../getset/), [`incr`](../incr/), [`incrby`](../incrby/), [`setrange`](../setrange/), [`strlen`](../strlen/) |