PostgreSQL: Fix index size computation in PostgreSQL < 9.0 (reverts 4c78976c)

This commit is contained in:
Jakub Vrana 2017-04-08 19:32:29 +02:00
parent 22d0cf4171
commit f556f6acb1
3 changed files with 5 additions and 2 deletions

View file

@ -244,7 +244,7 @@ ORDER BY 1";
function table_status($name = "") {
$return = array();
foreach (get_rows("SELECT c.relname AS \"Name\", CASE c.relkind WHEN 'r' THEN 'table' WHEN 'm' THEN 'materialized view' ELSE 'view' END AS \"Engine\", pg_relation_size(c.oid) AS \"Data_length\", pg_indexes_size(c.oid) AS \"Index_length\", obj_description(c.oid, 'pg_class') AS \"Comment\", c.relhasoids::int AS \"Oid\", c.reltuples as \"Rows\", n.nspname
foreach (get_rows("SELECT c.relname AS \"Name\", CASE c.relkind WHEN 'r' THEN 'table' WHEN 'm' THEN 'materialized view' ELSE 'view' END AS \"Engine\", pg_relation_size(c.oid) AS \"Data_length\", pg_total_relation_size(c.oid) - pg_relation_size(c.oid) AS \"Index_length\", obj_description(c.oid, 'pg_class') AS \"Comment\", c.relhasoids::int AS \"Oid\", c.reltuples as \"Rows\", n.nspname
FROM pg_class c
JOIN pg_namespace n ON(n.nspname = current_schema() AND n.oid = c.relnamespace)
WHERE relkind IN ('r', 'm', 'v')

View file

@ -1,2 +1,2 @@
<?php
$VERSION = "4.3.0";
$VERSION = "4.3.1-dev";

View file

@ -1,3 +1,6 @@
Adminer 4.3.1-dev:
PostgreSQL: Fix index size computation in PostgreSQL < 9.0 (regression from 4.3.0)
Adminer 4.3.0 (released 2017-03-15):
Make maxlength in edit fields a soft limit
Add accessibility labels