Deleting a cache

To completely remove a data cache, reset its size to 0:

sp_cacheconfig pubs_log, "0"

The cache is immediately deleted.

NoteYou cannot drop the default data cache.

If you delete a data cache to which objects are bound, the cache is left in memory and Adaptive Server issues:

Cache cache_name not deleted dynamically. Objects are bound to the cache. Use sp_unbindcache_all to unbind all objects bound to the cache.

The entry corresponding to the cache in the configuration file is deleted, as well as the entries corresponding to the cache in sysconfigures, and the cache is deleted the next time Adaptive Server is restarted.

If you re-create the cache and restart Adaptive Server, the bindings are marked valid again.

Use sp_helpcache to view all items bound to the cache. Use sp_unbindcache_all to unbind objects. See the Reference Manual: Procedures.