From: stan <stanb@panix.com>
To: Adrian Klaver <adrian.klaver@aklaver.com>
Cc: pgsql-general@postgresql.org
Subject: Re: FW: Re: FW: Re: Shouldn;t this trigger be called?
Date: Tue, 17 Sep 2019 05:31:26 -0400
Message-ID: <20190917093126.GA935@panix.com> (raw)
In-Reply-To: <4b1da094-8342-6415-e0a4-ce87fd1331ab@aklaver.com>
References: <20190915174649.GB2078@panix.com>
<50d5b256-74b9-1949-a634-0df37cbfb783@aklaver.com>
<20190916010439.GA7478@panix.com>
<11b4428d-8740-07f4-a053-37f0bb0cd2fb@aklaver.com>
<20190916185333.GB28966@panix.com>
<b1b8bfde-a836-c05f-fa2f-01ee29d93032@aklaver.com>
<20190916195543.GA16882@panix.com>
<4b1da094-8342-6415-e0a4-ce87fd1331ab@aklaver.com>
On Mon, Sep 16, 2019 at 03:19:27PM -0700, Adrian Klaver wrote:
> On 9/16/19 12:55 PM, stan wrote:
> >
> > On Mon, Sep 16, 2019 at 12:44:49PM -0700, Adrian Klaver wrote:
> > > On 9/16/19 11:53 AM, stan wrote:
> > > > On Sun, Sep 15, 2019 at 09:16:35PM -0700, Adrian Klaver wrote:
> > > > > On 9/15/19 6:04 PM, stan wrote:
> > > > > > On Sun, Sep 15, 2019 at 12:27:14PM -0700, Adrian Klaver wrote:
> > > > > > > On 9/15/19 10:46 AM, stan wrote:
> > > > > > > > Forgot to cc the list again. Have to look at settings in mutt.
> > > > > > > >
> > > > > > > > > > >
> > > > >
> > > > > > > What validity check?
> > > > > > >
> > > > > >
> > > > > > The check to see if it is the type enum.
> > > > > >
> > > > >
> > > > > This would get solved a lot quicker if full information was provided:
> > > > >
> > > > > 1) Schema of the table.
> > > > > Including associated triggers
> > > > >
> > > > > 2) The actual check code.
> > > > >
> > > >
> > > > OK, please let me know if what I put in my reply to Tom Lane is not sufficient.
> > > >
> > >
> > >
> > > It was not sufficient, you did not include the table schema or the check
> > > code.
> >
> > OK, understood here is the table:
> >
> > /* Contains one record for each customer */
> >
>
> > status activity_status NOT NULL DEFAULT 'ACTIVE',
> > modtime timestamptz NOT NULL DEFAULT current_timestamp
> > );
> >
> > I am not certain what you mean by the check. As you can see, there is nor
> > specific check clause. I was referring to the built in check of data being
> > entered versus the legal values for the user defined type. Make sense?
> >
>
> To be clear you are seeing an error because a value of say 'active' is being
> rejected before your trigger has a chance to upper case it, correct?
>
> Also this happens whether you use \copy or manually INSERT the values?
That is correct. Sorry this was not clear from the beginning.
Any suggestions, including changing the design here, are welcome.
--
"They that would give up essential liberty for temporary safety deserve
neither liberty nor safety."
-- Benjamin Franklin
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-general@postgresql.org
Cc: stanb@panix.com, adrian.klaver@aklaver.com
Subject: Re: FW: Re: FW: Re: Shouldn;t this trigger be called?
In-Reply-To: <20190917093126.GA935@panix.com>
References: <20190915174649.GB2078@panix.com> <50d5b256-74b9-1949-a634-0df37cbfb783@aklaver.com> <20190916010439.GA7478@panix.com> <11b4428d-8740-07f4-a053-37f0bb0cd2fb@aklaver.com> <20190916185333.GB28966@panix.com> <b1b8bfde-a836-c05f-fa2f-01ee29d93032@aklaver.com> <20190916195543.GA16882@panix.com> <4b1da094-8342-6415-e0a4-ce87fd1331ab@aklaver.com> <20190917093126.GA935@panix.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox