QueryCache and uncached

I’ve had an interesting issue come up. We use an uncached block around a select-insert-select for an unique constraint (the second select executing if the insert failed due to a race condition with another process), but the uncached is around the entire block for abstraction reasons (it’s a method called unique_constraint_retry that handles calling the block a second time if necessary). However, the query cache is not cleared for the insert inside the block, because caching is disabled. I was wondering if there’s a specific reason that the dirtying methods can’t clear the cache unconditionally?


Cody Cutrer