Array columns vs normalized table

From: Lee Hachadoorian <lee(dot)hachadoorian(at)gmail(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: Array columns vs normalized table
Date: 2010-03-02 17:21:24
Message-ID: 5ab13581003020921q3b5dd481mf118fa05f555fd7b@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

I work with state labor data which is reported to us in the form

industry, year, quarter1, quarter2, quarter3, quarter4

where each quarter represents an employment count. Obviously, this can
be normalized to

industry, year, quarter, employment

Can anyone comment on, or point to me to an article or discussion
regarding, why one would use an array column instead of normalizing
the data? That is, would there be any benefit to storing it as

industry int, year smallint, employment int[ ]

where the last column would be a four element array with data for the
four quarters.

Thanks,
--Lee

--
Lee Hachadoorian
PhD Student, Geography
Program in Earth & Environmental Sciences
CUNY Graduate Center

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Vick Khera 2010-03-02 17:48:07 disable triggers isolated to transaction only?
Previous Message Scott Bailey 2010-03-02 17:10:40 Re: to_timestamp() and quarters