Re: Passing an argument to a trigger function using tg_argv - Mailing list pgsql-novice

From Simon Connah
Subject Re: Passing an argument to a trigger function using tg_argv
Date
Msg-id Bqzd6DMc-KEWPsDCPB8chnP96GgNNJIQxfTjUQQYy5GXnCP2x9HuKnUBawyMYriU2jt5MmoT7wgXH6yi3B9-IOE1oLfHtfsfN9LfGRxbKW8=@protonmail.com
Whole thread Raw
In response to Re: Passing an argument to a trigger function using tg_argv  ("David G. Johnston" <david.g.johnston@gmail.com>)
Responses Re: Passing an argument to a trigger function using tg_argv  ("David G. Johnston" <david.g.johnston@gmail.com>)
List pgsql-novice
‐‐‐‐‐‐‐ Original Message ‐‐‐‐‐‐‐
On Thursday, April 1st, 2021 at 06:10, David G. Johnston <david.g.johnston@gmail.com> wrote:
On Wednesday, March 31, 2021, Simon Connah <simon.n.connah@protonmail.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.
Attachment

pgsql-novice by date:

Previous
From: "David G. Johnston"
Date:
Subject: Re: Passing an argument to a trigger function using tg_argv
Next
From: "David G. Johnston"
Date:
Subject: Re: Passing an argument to a trigger function using tg_argv