Обсуждение: launch a php script from a trigger function

Поиск
Список
Период
Сортировка

launch a php script from a trigger function

От
Steve.Toutant@inspq.qc.ca
Дата:

Hi,
I have little experience with postgres.
I successfully created a trigger function who does basic stuff such as UPDATE another table.

Now, I need to launch a php script from that trigger, something like php test.php.

Is it possible to do that?
thanks
Steve

Re: launch a php script from a trigger function

От
Steve.Toutant@inspq.qc.ca
Дата:

Thanks Randy,
The php script I need to send does not have effect on the transaction. Per example I don't need a rollback in the database if the php script fails.

Is it possible to launch a batch file ( ex. test.bat )
Steve




Randy Moller <zoomerz@comcast.net>

29/03/2010 04:42 PM

Veuillez répondre à
randy.moller@comcast.net

A
Steve.Toutant@inspq.qc.ca
cc
Objet
Re: [PHP] launch a php script from a trigger function







It is not possible to execute a script from a database. a php script can
be executed by a server daemon or scheduled cron, by cli on a terminal,
or, via http (over the web) through a browser. But the php parser does
not respond to commands by any database.

Hope this helps.

Randy

Steve.Toutant@inspq.qc.ca wrote:
>
> Hi,
> I have little experience with postgres.
> I successfully created a trigger function who does basic stuff such as
> UPDATE another table.
>
> Now, I need to launch a php script from that trigger, something like
> php test.php.
>
> Is it possible to do that?
> thanks
> Steve
> ------------------------------------------------------------------------
>
>
> No virus found in this incoming message.
> Checked by AVG - www.avg.com
> Version: 9.0.791 / Virus Database: 271.1.1/2777 - Release Date: 03/29/10 00:32:00
>
>