run shell command from pl/pgsql

Поиск
Список
Период
Сортировка
От Jules Alberts
Тема run shell command from pl/pgsql
Дата
Msg-id 200211180844.gAI8ieJO014717@artemis.cuci.nl
обсуждение исходный текст
Список pgsql-novice
Hello all,

I'm working on a pg database that should be able to run commands on
certain conditions. E.g. whenever a date is stored in column X of table
Y, an email should be sent to user Z. Creating a triggered function is
easy enough but how do I invoke the command? Also, I want to use
variables in the executed command, something like:

    m_address := ''me@myself.org'';
    m_subject := ''this is a test'';
    runcommand(''mail -s '' + m_subject + m_address);

I guess the answer is very obvious, but I couldn't find it. TIA for any
help!

--
Jules Alberts.

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

Предыдущее
От: Oliver Elphick
Дата:
Сообщение: Re: Help with PostgreSQL Access
Следующее
От: "Henshall, Stuart - Design & Print"
Дата:
Сообщение: Re: run shell command from pl/pgsql