dbSize

PHP Redis

dbSize

Description

Returns the current database's size.

返回当前DB的KEY的数量

Parameters

None.

Return value

INTEGER: DB size, in number of keys.

Example
$count = $redis->dbSize();
echo "Redis has $count keys\n";