Dear List,
Thanks for those who helped me with my last question.
I have a slightly related question:
I have five tables which are really intended to be one big table, but has been adapted to comply with Postgres's
(irritating)8kb tuple size limit (ver 7.0.3).
I have 'modtime' fields in each of these tables which record the last time a record was updated. But I would like the
behaviourto be such that a modtime field in each of these associated tables is updated when any of the tables are
updated. And I would like all of the modtime fields to take the same value if possible.
The primary/foreign keys for each of the tables do not necessarily have the same name.
I've currently imagined a trigger for each table that updates every other table every time it is updated. But I've not
hadmuch success executing SQL from inside a plpgsql function at the moment - and wouldn't it create a cycle of triggers
byupdating a table's modtime, which in turn causes another modtime update in all the other tables, which in turn
perpetuatesthe circle?
Any help greatly appreciated,
Thanks,
Rajit