Bookmarks

Yahoo Gmail Google Facebook Delicious Twitter Reddit Stumpleupon Myspace Digg

Search queries

nrao wwwxxx, xxxxxdup, procmail change subject header, wwwXxx not20, Wwwxxx.doks sas, linux raid resync after reboot, bind-address mysql multiple, sanibleone xxxx, ftp://192.168.100.100/, www.xxxcon

Links

XODOX
Impressum

#1: launch a php script from a trigger function

Posted on 2010-03-29 22:13:07 by Steve.Toutant

Message en plusieurs parties au format MIME
--=_alternative 006F10C3852576F5_=
Content-Type: text/plain; charset="US-ASCII"

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
--=_alternative 006F10C3852576F5_=
Content-Type: text/html; charset="US-ASCII"


<br><font size=2 face="sans-serif">Hi,</font>
<br><font size=2 face="sans-serif">I have little experience with postgres.</font>
<br><font size=2 face="sans-serif">I successfully created a trigger function
who does basic stuff such as UPDATE another table.</font>
<br>
<br><font size=2 face="sans-serif">Now, I need to launch a php script from
that trigger, something like php test.php.</font>
<br>
<br><font size=2 face="sans-serif">Is it possible to do that?</font>
<br><font size=2 face="sans-serif">thanks</font>
<br><font size=2 face="sans-serif">Steve</font>
--=_alternative 006F10C3852576F5_=--

Report this message

#2: Re: launch a php script from a trigger function

Posted on 2010-03-30 15:20:20 by Steve.Toutant

Message en plusieurs parties au format MIME
--=_alternative 004945FA852576F6_=
Content-Transfer-Encoding: quoted-printable
Content-Type: text/plain; charset="ISO-8859-1"

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 )=20
Steve





Randy Moller <zoomerz@comcast.net>=20
29/03/2010 04:42 PM
Veuillez r=E9pondre =E0
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=20
be executed by a server daemon or scheduled cron, by cli on a terminal,=20
or, via http (over the web) through a browser. But the php parser does=20
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=20
> UPDATE another table.
>
> Now, I need to launch a php script from that trigger, something like=20
> php test.php.
>
> Is it possible to do that?
> thanks
> Steve
> ------------------------------------------------------------ ------------
>
>
> No virus found in this incoming message.
> Checked by AVG - www.avg.com=20
> Version: 9.0.791 / Virus Database: 271.1.1/2777 - Release Date: 03/29/10 =

00:32:00
>
>=20





--=_alternative 004945FA852576F6_=
Content-Transfer-Encoding: quoted-printable
Content-Type: text/html; charset="ISO-8859-1"


<br><font size=3D2 face=3D"sans-serif">Thanks Randy,</font>
<br><font size=3D2 face=3D"sans-serif">The php script I need to send does n=
ot
have effect on the transaction. Per example I don't need a rollback in
the database if the php script fails.</font>
<br>
<br><font size=3D2 face=3D"sans-serif">Is it possible to launch a batch file
( ex. test.bat ) </font>
<br><font size=3D2 face=3D"sans-serif">Steve</font>
<p>
<p>
<br>
<br>
<br>
<table width=3D100%>
<tr valign=3Dtop>
<td width=3D40%><font size=3D1 face=3D"sans-serif"><b>Randy Moller &lt;zoom=
erz@comcast.net&gt;</b>
</font>
<p><font size=3D1 face=3D"sans-serif">29/03/2010 04:42 PM</font>
<table border>
<tr valign=3Dtop>
<td bgcolor=3Dwhite>
<div align=3Dcenter><font size=3D1 face=3D"sans-serif">Veuillez r=E9pondre =
=E0<br>
randy.moller@comcast.net</font></div></table>
<br>
<td width=3D59%>
<table width=3D100%>
<tr valign=3Dtop>
<td>
<div align=3Dright><font size=3D1 face=3D"sans-serif">A</font></div>
<td><font size=3D1 face=3D"sans-serif">Steve.Toutant@inspq.qc.ca</font>
<tr valign=3Dtop>
<td>
<div align=3Dright><font size=3D1 face=3D"sans-serif">cc</font></div>
<td>
<tr valign=3Dtop>
<td>
<div align=3Dright><font size=3D1 face=3D"sans-serif">Objet</font></div>
<td><font size=3D1 face=3D"sans-serif">Re: [PHP] launch a php script from a
trigger function</font></table>
<br>
<table>
<tr valign=3Dtop>
<td>
<td></table>
<br></table>
<br>
<br>
<br>
<br>
<br><tt><font size=3D2>It is not possible to execute a script from a databa=
se.
a php script can <br>
be executed by a server daemon or scheduled cron, by cli on a terminal,
<br>
or, via http (over the web) through a browser. But the php parser does
<br>
not respond to commands by any database.<br>
<br>
Hope this helps.<br>
<br>
Randy<br>
<br>
Steve.Toutant@inspq.qc.ca wrote:<br>
&gt;<br>
&gt; Hi,<br>
&gt; I have little experience with postgres.<br>
&gt; I successfully created a trigger function who does basic stuff such
as <br>
&gt; UPDATE another table.<br>
&gt;<br>
&gt; Now, I need to launch a php script from that trigger, something like
<br>
&gt; php test.php.<br>
&gt;<br>
&gt; Is it possible to do that?<br>
&gt; thanks<br>
&gt; Steve<br>
&gt; ------------------------------------------------------------ ----------=
--<br>
&gt;<br>
&gt;<br>
&gt; No virus found in this incoming message.<br>
&gt; Checked by AVG - www.avg.com <br>
&gt; Version: 9.0.791 / Virus Database: 271.1.1/2777 - Release Date: 03/29/=
10
00:32:00<br>
&gt;<br>
&gt; &nbsp; <br>
<br>
</font></tt>
<br>
<br>
<br>
--=_alternative 004945FA852576F6_=--

Report this message