php8.5
Home/ Manual/ memcached / memcached/ Memcached::deleteByKey

Memcached::deleteByKey

PHP function Edit on GitHub ✎

(PECL memcached >= 0.1.0)

Delete an item from a specific server

Description

Memcached::deleteByKey(string $server_key, string $key, int $time = 0): bool

Memcached::deleteByKey() is functionally equivalent to Memcached::delete, except that the free-form server_key can be used to map the key to a specific server.

Parameters

server_key

Server_key

key

The key to be deleted.

time

The amount of time the server will wait to delete the item.

Delete-time

Return Values

Success The Memcached::getResultCode will return Memcached::RES_NOTFOUND if the key does not exist.

See Also

  • Memcached::delete
  • Memcached::deleteMulti
  • Memcached::deleteMultiByKey

Source: reference/memcached/memcached/deletebykey.xml · from the official PHP manual (php/doc-en)