bigtables.py
changeset 83 515fadd3d286
parent 38 d3593869d624
child 93 b72591087495
--- a/bigtables.py	Wed Apr 10 11:22:15 2013 +0200
+++ b/bigtables.py	Sat Apr 13 15:22:05 2013 +0200
@@ -1,6 +1,7 @@
 #!/usr/bin/env python3.2
 
-from pgtoolkit import pgbrowser, toolbase, prettysize
+from pgtoolkit import pgbrowser, toolbase
+from pycolib import prettysize
 
 
 class BigTablesTool(toolbase.SimpleTool):
@@ -19,7 +20,7 @@
             for table in tables:
                 table_name = '%s.%s' % (schema['name'], table['name'])
                 all_tables.append({'name': table_name, 'size': table['size']})
-        
+
         # print names and sizes of 20 largest tables
         for table in sorted(all_tables, reverse=True, key=lambda x: x['size'])[:20]:
             print(prettysize.prettysize_short(table['size']).rjust(8), table['name'], sep='  ')