Welcome Guest, Not a member yet? Register   Sign In
CI db->cache_delete() only specific queries?
#1

[eluser]Unknown[/eluser]
Here's the scenario:

I have a db with many organizations in one table, and a table full of assets with a field indexing the organization key. I am pulling queries of select organizations and looping through all of their assets, using URL query string parameters for indicators as to what organizations to pull from.

Since this is a rather lengthy query it creates a performance drag on the server so I was thinking of using CI's db caching to cache the queries. Then, on asset update I want to delete the cache file of only the query that pertains to the particular organization and not wipe out the entire 'organization+asset' directory in which is resides. If I wipe out all of the cache files in 'organization+asset' upon single asset update the entire query must be rebuilt.

Is there flexibility in CI's db->cache_delete() to only delete cached instances inside the directory and not wipe out the entire 'organization+asset' dir?

Any help would be MUCH appreciated.

Thanks!




Theme © iAndrew 2016 - Forum software by © MyBB