| From: | Scott Ribe <scott_ribe(at)elevated-dev(dot)com> |
|---|---|
| To: | <mabra(at)manfbraun(dot)de> <mabra(at)manfbraun(dot)de> |
| Cc: | <pgsql-general(at)postgresql(dot)org> |
| Subject: | Re: Looking for auto starting procedures |
| Date: | 2010-12-02 22:21:54 |
| Message-ID: | BFC34919-6769-4F54-B123-A6FA53AF26B3@elevated-dev.com |
| Views: | Whole Thread | Raw Message | Download mbox | Resend email |
| Thread: | |
| Lists: | pgsql-general |
On Dec 2, 2010, at 1:27 PM, <mabra(at)manfbraun(dot)de> <mabra(at)manfbraun(dot)de> wrote:
>
> I have not understand, where I can issue direct sql statements
> and it looks like, the RAISE is not possible with plSql:
Right, it's not actually SQL, so you can't use it in plain SQL. It is part of the plpgsql procedural language.
So you could easily create a small stored procedure, for example:
create function myraise(msg varchar, id varchar) returns void as $$ begin
raise notice '%: %', msg, id;
end; $$ language plpgsql;
and call that from SQL:
select myraise ('mymsg', '1234');
--
Scott Ribe
scott_ribe(at)elevated-dev(dot)com
http://www.elevated-dev.com/
(303) 722-0567 voice
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Peter Eisentraut | 2010-12-02 22:44:55 | Re: How to find correct locale name for CREATEDATABASE |
| Previous Message | mabra | 2010-12-02 21:53:55 | Re: Looking for auto starting procedures |