Re: sql query - create replace function

Поиск
Список
Период
Сортировка
От Richard Huxton
Тема Re: sql query - create replace function
Дата
Msg-id 476A2861.2060905@archonet.com
обсуждение исходный текст
Ответ на sql query - create replace function  ("Iuri Sampaio" <iuri.sampaio@gmail.com>)
Список pgsql-sql
Iuri Sampaio wrote:
> Hi all,
> 
> I created a script to install postgresql. One of the steps is to run a sql
> query.
> 
> the problem is that i need to run the query as postgres user, plus it needs
> to be at psql shell prompt command line, i.e:

Why does it need to be at the psql prompt?

> I expected something like
> su - postgres -c "pgsql dbname && create or replace function bitfromint4
> (integer) returns bit varying as ' begin return $1::bit(32); end;' language
> 'plpgsql' immutable str\
> ict;"

What's wrong with this?

--   Richard Huxton  Archonet Ltd


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

Предыдущее
От: "Iuri Sampaio"
Дата:
Сообщение: sql query - create replace function
Следующее
От: "Philippe Lang"
Дата:
Сообщение: Concatenation through SQL