| От | Tom Lane |
|---|---|
| Тема | Re: Accessing fields past CATALOG_VARLEN |
| Дата | |
| Msg-id | 3915193.1641249333@sss.pgh.pa.us обсуждение |
| Ответ на | Accessing fields past CATALOG_VARLEN (Ed Behn <ed@behn.us>) |
| Список | pgsql-hackers |
Ed Behn <ed@behn.us> writes:
> I can get fields like procStruct->prokind and procStruct->proretset.
> However, I get a compiler error when I try to access procStruct->proargmodes.
> I know that this is because this field is in the CATALOG_VARLEN block which
> makes it invisible to the compiler.
> What is the proper way to get this field?
SysCacheGetAttr(). There are examples all over the tree, but
one that's specific to proargmodes (and also illustrates the
best practices for deciphering its value) is in
parser/analyze.c's transformCallStmt().
You should also ask yourself if you really *need* to examine
proargmodes for yourself, or if there's a utility function
somewhere that will compute what you need to know.
regards, tom lane
В списке pgsql-hackers по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера