Declare Cursor question again

Поиск
Список
Период
Сортировка
От Dr. Michael Meskes
Тема Declare Cursor question again
Дата
Msg-id 19980805211840.A515@feivel.online-club.de
обсуждение исходный текст
Список pgsql-hackers
Is the following legal:

if (<condition>) {
        exec sql declare cur cursor for
                select name, nr from table where nr < 10;
}
else {
        exec sql declare cur cursor for
                select name, nr from table where nr >= 10;
}


That is declaring one cursor in two different ways? Oracle cannot do that.
We can, though. Shall I disable this (and remove my last changes) or is this
a good feature (as I think it is) and we keep it? Only disadvantage is that
the declare tarnslates into a C statement and is not really a declaration
anymore.

Michael
--
Dr. Michael Meskes        meskes@online-club.de, meskes@debian.org
Go SF49ers! Go Rhein Fire!    Use Debian GNU/Linux!

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

Предыдущее
От: Roland Roberts
Дата:
Сообщение: How do I find the table that an oid belongs to
Следующее
От: "Dr. Michael Meskes"
Дата:
Сообщение: Re: [HACKERS] Standards question