Re: Scalability with large numbers of tables - Mailing list pgsql-general

From Christopher Browne
Subject Re: Scalability with large numbers of tables
Date
Msg-id 37u41vF5e6768U2@individual.net
Whole thread Raw
In response to Scalability with large numbers of tables  (Phil Endecott <spam_from_postgresql_general@chezphil.org>)
List pgsql-general
I'm pretty sure that slowness of tab completion has little to do with
the performance of the filesystems.

If you've got tens of thousands of relations, the tab completion code
has to draw the whole list of relations from pg_class into memory and
"marshal" it into a form usable by GNU Readline.  THAT is what you're
seeing slow down.  As the number of tables, n, grows, the cost of that
grows with order of complexity O(n).

Actual queries on actual tables won't be slow; they will look up
relation names directly in pg_class, and presumably go from there to
get the file name(s) on the filesystem, which each represent
operations of complexity of order O(n log n).  Which remains fast even
if
--
(format nil "~S@~S" "cbbrowne" "gmail.com")
http://linuxdatabases.info/info/slony.html
It isn't that  physicists enjoy physics  more than they enjoy sex, its
that they enjoy sex more when they are thinking of physics.

pgsql-general by date:

Previous
From: Christopher Browne
Date:
Subject: Re: Ways to speed up dump&reload
Next
From: "Florian G. Pflug"
Date:
Subject: Re: Scalability with large numbers of tables