Re: unable to assign value to variable in plpgsql

Поиск
Список
Период
Сортировка
От Chirag Mittal
Тема Re: unable to assign value to variable in plpgsql
Дата
Msg-id 1392569485780-5792298.post@n5.nabble.com
обсуждение исходный текст
Ответ на Re: unable to assign value to variable in plpgsql  (David Johnston <polobo@yahoo.com>)
Список pgsql-novice
Thanks everyone for your help, I did the following and it worked


maz := (SELECT count(*) FROM table WHERE col1 = var1);
EXECUTE 'SELECT count(*) FROM table WHERE col1 = $1'
USING col1 INTO maz;

"in" was a typo and var type along with query was under declare (hope this
is right practice techincaly)





--
View this message in context:
http://postgresql.1045698.n5.nabble.com/unable-to-assign-value-to-variable-in-plpgsql-tp5792281p5792298.html
Sent from the PostgreSQL - novice mailing list archive at Nabble.com.


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

Предыдущее
От: David Johnston
Дата:
Сообщение: Re: unable to assign value to variable in plpgsql
Следующее
От: Andrew Puschak
Дата:
Сообщение: Re: Access 2003 reports queries taking very long