Re: flinfo NULL in DirectFunctionCall callee?

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: flinfo NULL in DirectFunctionCall callee?
Дата
Msg-id 31067.1566832318@sss.pgh.pa.us
обсуждение исходный текст
Ответ на flinfo NULL in DirectFunctionCall callee?  (Paul A Jungwirth <pj@illuminatedcomputing.com>)
Ответы Re: flinfo NULL in DirectFunctionCall callee?  (Paul A Jungwirth <pj@illuminatedcomputing.com>)
Список pgsql-general
Paul A Jungwirth <pj@illuminatedcomputing.com> writes:
> Is it expected for flinfo to be null when using DirectFunctionCall*?

Yes, per the comment on those functions:

 * These are for invocation of a specifically named function with a
 * directly-computed parameter list.  Note that neither arguments nor result
 * are allowed to be NULL.  Also, the function cannot be one that needs to
 * look at FmgrInfo, since there won't be any.

> Is there something else I should use instead? It looks like
> FunctionCall2 would let me pass my own flinfo, but I'm not sure how to
> set that up first.

Use fmgr_info() or a sibling to fill in the FmgrInfo.

            regards, tom lane



В списке pgsql-general по дате отправления:

Предыдущее
От: Paul A Jungwirth
Дата:
Сообщение: flinfo NULL in DirectFunctionCall callee?
Следующее
От: Jeremy Thomason
Дата:
Сообщение: import job not working