| От | Richard Huxton |
|---|---|
| Тема | Re: adressing column |
| Дата | |
| Msg-id | 200310011246.48878.dev@archonet.com обсуждение исходный текст |
| Ответ на | adressing column (Stefan Leitich <steffn@gmx.at>) |
| Список | pgsql-general |
On Wednesday 01 October 2003 11:20, Stefan Leitich wrote: > i have the following function: [snip code] > > now i am searching for a way, to access my_column in my_record (now it > just works if my_column = 'col') > can anyone help please! That's not going to work in plpgsql at the moment. Because it's "compiled", it has problems with things like this. The usual answer is to use pltcl or some other more dynamic language. In you particular example you could just build your execute statement as: ... || my_column || ' AS foo FROM ' || ... Then you can access the column as "foo" -- Richard Huxton Archonet Ltd
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера