企业🤖AI智能体构建引擎,智能编排和调试,一键部署,支持知识库和私有化部署方案 广告
## ttl, pttl ##### *Description* Returns the time to live left for a given key, in seconds. If the key doesn't exist, `<span class="calibre12">FALSE</span>` is returned. pttl returns a time in milliseconds. 取得一个KEY已经存在的时间。如果这个KEY不存在,则返回FLASE。PTTL使用毫秒为单位。 ##### *Parameters* *Key*: key ##### *Return value* Long, the time left to live in seconds. ##### *Example* ``` <pre class="calibre9">$redis->ttl('key'); ```