Re: tricky pivot query
From: Jared Still <jkstill_at_gmail.com>
Date: Wed, 11 Jun 2008 09:19:37 -0700
Message-ID: <bf46380806110919g6112e609kb19596f58ee9a27f@mail.gmail.com>
Date: Wed, 11 Jun 2008 09:19:37 -0700
Message-ID: <bf46380806110919g6112e609kb19596f58ee9a27f@mail.gmail.com>
On Tue, Jun 10, 2008 at 10:10 PM, Anthony Wilson <amwilson_at_iinet.net.au>
wrote:
> Argh!! Why don't people store dates as DATESs???
>
It's perfectly normal (yes, that was a pun) to store dates in this manner in a DW environment.
That said, the way it was done in this example wasn't so good.
It would be better if the date were stored with the data, and the day_id, month_id, etc, were stored in a separate date table.
See Kimball's "Data Warehouse Toolkit" for a good example of that.
-- Jared Still Certifiable Oracle DBA and Part Time Perl Evangelist -- http://www.freelists.org/webpage/oracle-lReceived on Wed Jun 11 2008 - 11:19:37 CDT