Re: PL/pgSQL doesn't support variables in queries?

Поиск
Список
Период
Сортировка
От hubert depesz lubaczewski
Тема Re: PL/pgSQL doesn't support variables in queries?
Дата
Msg-id ZFJUFK5bDvpSIKFH@depesz.com
обсуждение исходный текст
Ответ на PL/pgSQL doesn't support variables in queries?  ("J.A." <postgresql@world-domination.com.au>)
Список pgsql-general
On Wed, May 03, 2023 at 10:25:55PM +1000, J.A. wrote:
> Heya folks :)
> 
> ms-sql person here migrating over to pgsql. One of the first thing's I
> noticed with pgsql (or more specifically, PL/pgSQL) is that it doesn't
> support "variables" in a query?
> 
> for example, here's some T-SQL:
> 
> DECLARE @fkId INTEGER

Sure it does.

There is nothing relating to "@" character, though.

You can easily find examples in docs:
https://www.postgresql.org/docs/current/plpgsql-structure.html

depesz



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

Предыдущее
От: "J.A."
Дата:
Сообщение: PL/pgSQL doesn't support variables in queries?
Следующее
От: Michael Loftis
Дата:
Сообщение: Re: libpq and multi-threading