GET
AttentionThis page documents an earlier version. Go to the latest (v2.1)version.
Synopsis
GET key
This command fetches the value that is associated with the given key
.
- If the
key
does not exist, null is returned. - If the
key
is associated with a non-string value, an error is raised.
Return Value
Returns string value of the given key
.
Examples
You can do this as shown below.
$ GET yugakey
(null)
$ SET yugakey "Yugabyte"
"OK"
$ GET yugakey
"Yugabyte"
See Also
append
, getrange
, getset
, incr
, incrby
, set
, setrange
, strlen
当前内容版权归 YugabyteDB 或其关联方所有,如需对内容或内容相关联开源项目进行关注与资助,请访问 YugabyteDB .