X-Original-To: pgsql-sql@postgresql.org Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id EA501476193 for ; Fri, 28 Feb 2003 08:01:44 -0500 (EST) Received: from postgresql.org ([64.49.215.8]) by localhost (postgresql.org [64.49.215.8:10024]) (amavisd-new) with SMTP id 34206-02 for ; Fri, 28 Feb 2003 08:01:29 -0500 (EST) Received: from home.dialix.com (unknown [216.14.192.249]) by postgresql.org (Postfix) with ESMTP id 624894761A1 for ; Fri, 28 Feb 2003 01:31:15 -0500 (EST) Received: from oemcomputer (dialup-35.37.194.203.acc01-stge-pth.comindico.com.au [203.194.37.35]) by home.dialix.com (8.11.6/8.9.3/JustNet) with SMTP id h1S6Wkk48621 for ; Fri, 28 Feb 2003 17:32:47 +1100 (EST) (envelope-from susan@perth.dialix.com.au) Message-ID: <001501c2def2$fe2fe9c0$1f84fea9@oemcomputer> From: "Susan Hoddinott" To: Subject: Executing SQL commands via triggers without the use of procedures Date: Fri, 28 Feb 2003 14:31:12 +0800 MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="----=_NextPart_000_0011_01C2DF36.0AC1DB60" X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 5.00.2919.6600 X-MimeOLE: Produced By Microsoft MimeOLE V5.00.2919.6600 X-Virus-Scanned: by amavisd-new X-Archive-Number: 200302/633 X-Sequence-Number: 12031 This is a multi-part message in MIME format. ------=_NextPart_000_0011_01C2DF36.0AC1DB60 Content-Type: multipart/alternative; boundary="----=_NextPart_001_0012_01C2DF36.0AC1DB60" ------=_NextPart_001_0012_01C2DF36.0AC1DB60 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable Hello, Having scoured the relevant documentation I cannot find anything which indi= cates how I simply create a database trigger to insert into a second table = after insert on a first table, without the use of a procedure. As I do not= want return values etc. this seems like overkill. Is it possible to creat= e a trigger which executes SQL directly without the need to create a proced= ure? If so, what is the syntax? Regards ------=_NextPart_001_0012_01C2DF36.0AC1DB60 Content-Type: text/html; charset="iso-8859-1" Content-Transfer-Encoding: quoted-printable
Hello,
 
Having scoured the relevant documentation = I cannot=20 find anything which indicates how I simply create a database trigger to ins= ert=20 into a second table after insert on a first table, without the use of a=20 procedure.  As I do not want return values etc. this seems like=20 overkill.  Is it possible to create a trigger which executes SQL direc= tly=20 without the need to create a procedure?  If so, what is the=20 syntax?
 
Regards
------=_NextPart_001_0012_01C2DF36.0AC1DB60-- ------=_NextPart_000_0011_01C2DF36.0AC1DB60 Content-Type: application/octet-stream; name="Susan Hoddinott.vcf" Content-Transfer-Encoding: 7bit Content-Disposition: attachment; filename="Susan Hoddinott.vcf" BEGIN:VCARD VERSION:2.1 N:Hoddinott;Susan FN:Susan Hoddinott EMAIL;INTERNET:susan@perth.dialix.com.au EMAIL;PREF;INTERNET:susan@hexworx.com REV:20030228T063112Z END:VCARD ------=_NextPart_000_0011_01C2DF36.0AC1DB60--