Re: Passing an argument to a trigger function using tg_argv

From: Simon Connah <simon(dot)n(dot)connah(at)protonmail(dot)com>
To: "David G(dot) Johnston" <david(dot)g(dot)johnston(at)gmail(dot)com>
Cc: "pgsql-novice(at)lists(dot)postgresql(dot)org" <pgsql-novice(at)lists(dot)postgresql(dot)org>
Subject: Re: Passing an argument to a trigger function using tg_argv
Date: 2021-04-01 05:16:15
Message-ID: Bqzd6DMc-KEWPsDCPB8chnP96GgNNJIQxfTjUQQYy5GXnCP2x9HuKnUBawyMYriU2jt5MmoT7wgXH6yi3B9-IOE1oLfHtfsfN9LfGRxbKW8=@protonmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-novice

‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐
On Thursday, April 1st, 2021 at 06:10, David G. Johnston <david(dot)g(dot)johnston(at)gmail(dot)com> wrote:

> On Wednesday, March 31, 2021, Simon Connah <simon(dot)n(dot)connah(at)protonmail(dot)com> wrote:
>

> > ‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐
> >

> > error: invalid input syntax for type bigint: "blog_user_id"
>

> You should read the “arguments” description under the create trigger syntax.   It explains why when you wrote the column name blog_user_id is tried to interpret that as a bigint (since that is the parameter type for the trigger function).
>

> David J.

Sorry if I am misunderstanding. I'm still pretty new to PostgreSQL but the column actually is a bigint (well technically a bigserial) which is why I am confused.

Simon.

In response to

Responses

Browse pgsql-novice by date

  From Date Subject
Next Message David G. Johnston 2021-04-01 05:25:22 Re: Passing an argument to a trigger function using tg_argv
Previous Message David G. Johnston 2021-04-01 05:10:57 Re: Passing an argument to a trigger function using tg_argv