From: | Richard Broersma Jr <rabroersma(at)yahoo(dot)com> |
---|---|
To: | chester c young <chestercyoung(at)yahoo(dot)com> |
Cc: | sql pgsql <pgsql-sql(at)postgresql(dot)org> |
Subject: | Re: Advice for generalizing trigger functions |
Date: | 2007-12-26 20:20:13 |
Message-ID: | 321939.8466.qm@web31804.mail.mud.yahoo.com |
Views: | Raw Message | Whole Thread | Download mbox | Resend email |
Thread: | |
Lists: | pgsql-sql |
--- On Wed, 12/26/07, chester c young <chestercyoung(at)yahoo(dot)com> wrote:
> what I do for change log is to have one change log table with table_id
> and column_id attributes that refer by to my internal meta_table and
> meta_column tables. this always works and is in the end, I have found,
> a bit more flexible, allowing you to search for changed columns, for
> example.
I agree that EAV history tables are far more flexible than creating separate history tables for each base table. Especially since this design choice does not require modifications when tables are created, altered, or dropped. However, I was looking to utilize functionality that an EAV history table can't provide.
For example, I replace joins to the Project.Managers table with joins to the History.Managers table and with a timestamp of interest to reproduce query results of the database's state that existed in "times passed".
If I didn't need to regularly provide this functionality, I would certainly use an EAV history table.
Regards,
Richard Broersma Jr.
From | Date | Subject | |
---|---|---|---|
Next Message | Richard Broersma Jr | 2007-12-26 20:22:03 | Re: need help |
Previous Message | A. Wiryawan | 2007-12-26 19:19:29 | need help |