pg.ddx.io  pgsql-general@postgresql.org mailing list archive  
help / color / mirror / Atom feed
From: Adrian Klaver <adrian.klaver@aklaver.com>
To: Mark Lybarger <mlybarger@gmail.com>
To: pgsql-general@postgresql.org
Subject: Re: version 0 calling convention
Date: Thu, 22 Jul 2021 09:21:27 -0700
Message-ID: <fd26d2ec-d1cf-9cb5-ad13-11dd60b45c96@aklaver.com> (raw)
In-Reply-To: <CAKM-gmKKb7WrOtxCHjV-qwOyV_cdZQbY0ewhtaoUkoVqJD-2iA@mail.gmail.com>
References: <CAKM-gmKKb7WrOtxCHjV-qwOyV_cdZQbY0ewhtaoUkoVqJD-2iA@mail.gmail.com>

On 7/22/21 9:18 AM, Mark Lybarger wrote:
> i have some sql functions written in c code using version 0 calling 
> convention.  it's working fine on postgresql 9.6, but i'm migrating to 
> v13.  has this calling convention been removed?

https://www.postgresql.org/docs/13/xfunc-c.html#id-1.8.3.13.7

"Currently only one calling convention is used for C functions (“version 
1”). Support for that calling convention is indicated by writing a 
PG_FUNCTION_INFO_V1() macro call for the function, as illustrated below."

> 
> my function creation give an error,
> 
> SQL Error [42883]: ERROR: could not find function information for 
> function "test_func"
>    Hint: SQL-callable functions need an accompanying 
> PG_FUNCTION_INFO_V1(funcname).


-- 
Adrian Klaver
adrian.klaver@aklaver.com





view thread (3+ messages)  latest in thread

Message-ID: <fd26d2ec-d1cf-9cb5-ad13-11dd60b45c96@aklaver.com>
Permalink:  ../fd26d2ec-d1cf-9cb5-ad13-11dd60b45c96@aklaver.com/
Also on:    postgresql.org/message-id/fd26d2ec-d1cf-9cb5-ad13-11dd60b45c96@aklaver.com

 · 

reply

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: adrian.klaver@aklaver.com, mlybarger@gmail.com
  Subject: Re: version 0 calling convention
  In-Reply-To: <fd26d2ec-d1cf-9cb5-ad13-11dd60b45c96@aklaver.com>
  References: <CAKM-gmKKb7WrOtxCHjV-qwOyV_cdZQbY0ewhtaoUkoVqJD-2iA@mail.gmail.com> <fd26d2ec-d1cf-9cb5-ad13-11dd60b45c96@aklaver.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