Re: [SQL] Using bind variable within BEGIN END

Поиск
Список
Период
Сортировка
От David G. Johnston
Тема Re: [SQL] Using bind variable within BEGIN END
Дата
Msg-id CAKFQuwaiTzfHmkxU06cxxV=g73xD4mSxSvqSfFh9y0DD41sC9g@mail.gmail.com
обсуждение исходный текст
Ответ на YNT: Re: [SQL] Using bind variable within BEGIN END  (gulsumramazanoglu <gulsumramazanoglu@gmail.com>)
Список pgsql-sql
On Friday, June 2, 2017, gulsumramazanoglu <gulsumramazanoglu@gmail.com> wrote:
David hi, if PostgreSQL doesnt have stored procedures and function can only be used by a SQL command, so we cannot make a call to an SQL script (of any kind, name it procedure or something) directly from a HLL program.. do i understand correctly?

I don't think so but I cannot figure out what your actual confusion is.  Write a function.  Execute a statement that invokes the function.  Remain connected until the function returns.  Learn whether it completed successfully or not and react accordingly. Move on in your HLL (higher level language?) code.

The term procedure in sql often implies autonomous which client invoked code cannot presently do (i.e., disconnect the connection after initiating the code but before it completes).

Your syntax issues are mostly about not having read the right sections of the docs pertaining to those syntactic issues.  Once you get past that you should be able to do most things that you can imagine.

David J.

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

Предыдущее
От: gulsumramazanoglu
Дата:
Сообщение: YNT: Re: [SQL] Using bind variable within BEGIN END
Следующее
От: "David G. Johnston"
Дата:
Сообщение: Re: [SQL] Using bind variable within BEGIN END