Any DBA's in the house?
James Antill
james at fedoraproject.org
Mon Jun 15 21:17:39 UTC 2009
On Mon, 2009-06-15 at 14:56 -0500, Mike McGrath wrote:
> Is it better to have:
>
> id | smallString1 | smallString2 | smallString3 | largerString1
>
> or put the largerString1 in it's own table?
Assuming the above is in normal form, I doubt it matters in general.
In specific cases I guess it's possible that having a separate table
could be better, but for instance PostgreSQL automatically out of lines
all large objects:
http://postgresql.mirrors-r-us.net/docs/8.2/static/storage-file-layout.html
A table that has columns with potentially large entries will
have an associated TOAST table, which is used for out-of-line
storage of field values that are too large to keep in the table
rows proper. pg_class.reltoastrelid links from a table to its
TOAST table, if any. See Section 52.2 for more information.
http://www.postgresql.org/docs/8.3/static/lo.html
--
James Antill <james at fedoraproject.org>
Fedora
More information about the Fedora-infrastructure-list
mailing list