Re: SQL Statement Help Needed - Mailing list pgsql-novice

From Charley Tiggs
Subject Re: SQL Statement Help Needed
Date
Msg-id 1EF00931-07B8-4551-AA6D-8124194157AA@xpressdocs.com
Whole thread Raw
In response to Re: SQL Statement Help Needed  (<me@alternize.com>)
List pgsql-novice
On Dec 5, 2005, at 10:44 PM, <me@alternize.com> <me@alternize.com>
wrote:

> correct me if i'm wrong, but i don't think having a completely
> normalized datastructure makes always sense. if one would need to
> query an employee and having all phone numbers & stuff in one
> single view, you'll end up having a huge amount of joins. this is
> bound to "cost" performance while the "win" (diskspace) is
> relatively small.

Actually, it depends on what you're after in the long run.  De-
normalizing phone numbers might make sense if all you really need is
the current contact information for a particular user.  But if you
really need a history of sorts of the contact information associated
with a user, normalization makes all the sense in the world.  As
well, you can't really predict how your information needs will
evolve.  You can make educated guesses but you really can't say,
"We'll never need that." As always, make a decision based on your
particular situation and what your needs are.  It also doesn't hurt
to plan a little for things that may never happen but could.  The
more you do so, the less traumatic it will be to change later.

Charley

pgsql-novice by date:

Previous
From: Jim Beckstrom
Date:
Subject: Pl/pgsql import
Next
From: Tom Lane
Date:
Subject: Re: \list