pgpool2.git / summary / log / commit / refs
commit 1e80d52e27cde63b0ae58499e8aa69d00bb565d1
Author: Nozomi Anzai <anzai@sraoss.co.jp>
Date: Mon Aug 20 04:25:19 2012 +0000
Fix query cache to ignore multi statement
In previous, queries like "SELECT 1;UPDATE..." were cached, too, but it was wrong.
pool_proto_modules.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/pool_proto_modules.c b/pool_proto_modules.c
index 92546bc5a..9d1e7283f 100644
--- a/pool_proto_modules.c
+++ b/pool_proto_modules.c
@@ -370,7 +370,7 @@ POOL_STATUS SimpleQuery(POOL_CONNECTION *frontend,
/*
* If the table is to be cached, set is_cache_safe TRUE and register table oids.
*/
- if (pool_config->memory_cache_enabled)
+ if (pool_config->memory_cache_enabled && query_context->is_multi_statement == false)
{
bool is_select_query = false;
int num_oids;
[parent: 71825ec9c27a]