Re: [HACKERS] RULE (and ALTER TABLE) questions - Mailing list pgsql-hackers

From jwieck@debis.com (Jan Wieck)
Subject Re: [HACKERS] RULE (and ALTER TABLE) questions
Date
Msg-id m10BO5B-000EBRC@orion.SAPserv.Hamburg.dsh.de
Whole thread Raw
In response to Re: [HACKERS] RULE (and ALTER TABLE) questions  (Hannu Krosing <hannu@trust.ee>)
List pgsql-hackers
> But when doing that at the table creation time, then the table can
> actually
> be defined as a view on storage table and rules for insert update and
> delete
> be defined for this view that do the actual data manipulation on the
> storage table.

    That's  IMHO  a too specific case to do it generally with the
    rule system.  Should be some kind of  constraint  handled  by
    the  parser  in  putting  an  UPPER()  func  node  around the
    targetlist expression.

    There could be more general support implemented,  in  that  a
    user can allways tell that a custom function should be called
    with the result of the TLE-expr before the value  is  dropped
    into the tuple on INSERT/UPDATE.


Jan

--

#======================================================================#
# It's easier to get forgiveness for being wrong than for being right. #
# Let's break this rule - forgive me.                                  #
#======================================== jwieck@debis.com (Jan Wieck) #

pgsql-hackers by date:

Previous
From: Hannu Krosing
Date:
Subject: Re: [HACKERS] RULE (and ALTER TABLE) questions
Next
From: "Ken Mort"
Date:
Subject: 8K block limit