postgresql_default.conf: Split "queries" query into two versions.
authorSebastian Harl <sh@tokkee.org>
Tue, 26 Aug 2008 14:11:26 +0000 (16:11 +0200)
committerFlorian Forster <octo@huhu.verplant.org>
Tue, 26 Aug 2008 17:09:09 +0000 (19:09 +0200)
The "n_tup_hot_upd" column has been added in 8.3. The two versions of the
"queries" query now take that into account by defining different SQL queries
for versions up to 8.2.99 and versions starting with 8.3.

Signed-off-by: Sebastian Harl <sh@tokkee.org>
Signed-off-by: Florian Forster <octo@huhu.verplant.org>
src/postgresql_default.conf

index decf39f..61844a0 100644 (file)
 </Query>
 
 <Query queries>
+       Query "SELECT sum(n_tup_ins), sum(n_tup_upd), sum(n_tup_del) \
+               FROM pg_stat_user_tables;"
+
+       Column pg_n_tup_c ins
+       Column pg_n_tup_c upd
+       Column pg_n_tup_c del
+
+       MaxPGVersion 80299
+</Query>
+
+<Query queries>
        Query "SELECT sum(n_tup_ins), sum(n_tup_upd), sum(n_tup_del), \
                        sum(n_tup_hot_upd) \
                FROM pg_stat_user_tables;"
@@ -30,6 +41,8 @@
        Column pg_n_tup_c upd
        Column pg_n_tup_c del
        Column pg_n_tup_c hot_upd
+
+       MinPGVersion 80300
 </Query>
 
 <Query query_plans>