Interaction Record (Journal Table?)
Interaction Record (Journal Table?)
От:
"Clark C . Evans" <clark.evans@manhattanproject.com>
Дата:
I was thinking that for the application I'm
working on, it'd be nice to have a journal
(as an XML fragment) which describes the
interactions within the database...
3493
Clark
Evans
Cameron
I was wondering if anyone has done
something similar? If so, what
approach did you use and is it
published as a reuseable module?
If not... how would you go about
approaching this? I suppose it could
all fit in a "journal" table using
arrays?
JOURNAL has 6 columns:
action, target_table, where_columns, where_values, columns, values
INSERT INTO JOURNAL VALUES ('insert','person'
,NULL,NULL,
['id','given','family'],[3493,'Clark','Evans']);
INSERT INTO JOURNAL VALUES ('update','person',
['id'], [3439],
['middle'],['Cameron']);
INSERT INTO JOURNAL VALUES ('delete','person',
['id'],[3439],
NULL,NULL);
I guess this would be better in the spirit of
PostgreSQL... in this way one can easily make
the dump of the SQL above...
Thoughts?
Clark
----- End forwarded message -----