Re: how to know when a table is altered

From: Ed Loehr <eloehr(at)austin(dot)rr(dot)com>
To: Vincenzo Passoli <maweb(at)hotmail(dot)com>
Cc: pgsql-sql(at)postgresql(dot)org
Subject: Re: how to know when a table is altered
Date: 2000-06-07 13:36:13
Message-ID: 393E4FCD.1E5D5BC1@austin.rr.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

Vincenzo Passoli wrote:
>
> i'm developing a framework (mod_perl+apache) that reads the db-schema and
> explode html forms.
>
> now i read the schema and cache it into perl-hashes to speedup things.
>
> my problem is to recognise when a table is altered so that the framework can
> update the related forms connected to the db tables.
> i don't want to read the schema every time.
>
> How can i implement this ?

My sub-optimal approach was to cache all of the generally static tables
(requiring a restart to reload them if they changed), and query the
rest. You can avoid a lot of joins by querying the db for the foreign
keys to static tables and then looking them up only in the app cache.
But caching query results and invalidating them when the underlying
tables changed would greatly simplify my app and speed things up, so I'd
love to hear if others have a better/faster solution here.

Regards,
Ed Loehr

In response to

Responses

Browse pgsql-sql by date

  From Date Subject
Next Message mikeo 2000-06-07 14:14:23 Re: [SQL] oracle rownum equivalent?
Previous Message Ed Loehr 2000-06-07 13:29:13 Re: [SQL] oracle rownum equivalent?