Skip site navigation (1) Skip section navigation (2)

Re: postgres launch os applications

From: mrbuseco(at)buseco(dot)net
To: "Andreas Kretschmer" <akretschmer(at)spamfence(dot)net>
Cc: pgsql-novice(at)postgresql(dot)org
Subject: Re: postgres launch os applications
Date: 2008-10-07 18:07:06
Message-ID: 20081007110706.1b404da78c54173e561a97484ed23969.a94cb6a614.wbe@email.secureserver.net (view raw or flat)
Thread:
Lists: pgsql-novice
<html><body><span style="font-family:Verdana; color:#000000; font-size:10pt;">One could use an embedded SQL C program to update the table, and then have that<br>same program invoke another executable via exec() or system() calls.<br><br>If you are using Apache and this is an update based on form data from an HTML<br>document (aren't we all?), one should already be using CGI-BIN programming with<br>embedded SQL and be able to fit this right in.<br><br>Matt<br><br>
<blockquote webmail="1" style="border-left: 2px solid blue; margin-left: 8px; padding-left: 8px; font-size: 10pt; color: black; font-family: verdana;">
-------- Original Message --------<br>
Subject: Re: [NOVICE] postgres launch os applications<br>
From: Andreas Kretschmer &lt;akretschmer(at)spamfence(dot)net&gt;<br>
Date: Tue, October 07, 2008 10:39 am<br>
To: pgsql-novice(at)postgresql(dot)org<br>
<br>
Ertel, Steve &lt;Steve(dot)Ertel(at)infimatic(dot)com&gt; schrieb:<br>
<br>
&gt; I am trying to start an OS executable every time that a table is updated.  I<br>
&gt; know that I should create a trigger on the table, but how do I launch the OS<br>
&gt; executable.  I have a background in sql server.  In it we would use something<br>
&gt; like xsp_execute().  I am looking for the equivalent function call in Postgres.<br>
<br>
Write a trigger-function using an untrusted language like pl/perlU. You<br>
can call arbitray commands within an untrusted language. With the<br>
regular trusted languages such plpgsql or so you can't call external<br>
programs.<br>
<br>
<br>
Andreas<br>
-- <br>
Really, I'm not out to destroy Microsoft. That will just be a completely<br>
unintentional side effect.                              (Linus Torvalds)<br>
"If I was god, I would recompile penguin with --enable-fly."   (unknown)<br>
Kaufbach, Saxony, Germany, Europe.              N 51.05082°, E 13.56889°<br>
<br>
-- <br>
Sent via pgsql-novice mailing list (pgsql-novice(at)postgresql(dot)org)<br>
To make changes to your subscription:<br>
<a href="http://www.postgresql.org/mailpref/pgsql-novice" target="_blank" mce_href="http://www.postgresql.org/mailpref/pgsql-novice">http://www.postgresql.org/mailpref/pgsql-novice</a><br>

</blockquote></span></body></html>


Attachment: unknown_filename
Description: text/html (2.2 KB)

pgsql-novice by date

Next:From: Sean DavisDate: 2008-10-07 18:12:46
Subject: Re: postgres launch os applications
Previous:From: Andreas KretschmerDate: 2008-10-07 17:39:46
Subject: Re: postgres launch os applications

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group