Received: from mail1.hub.org (webmail.hub.org [216.126.85.1]) by postgresql.org (8.11.3/8.11.4) with ESMTP id f9FNbLP72831 for ; Mon, 15 Oct 2001 19:37:21 -0400 (EDT) (envelope-from josh@agliodbs.com) Received: from davinci.ethosmedia.com (davinci.ethosmedia.com [209.10.40.250]) by mail1.hub.org (8.11.3/8.11.4) with ESMTP id f9FFKUX37607 for ; Mon, 15 Oct 2001 11:20:30 -0400 (EDT) (envelope-from josh@agliodbs.com) Received: from [209.10.40.250] (account ) by davinci.ethosmedia.com (CommuniGate Pro WebUser 3.4.1) with HTTP id 147888; Mon, 15 Oct 2001 08:20:24 -0700 From: "Josh Berkus" Subject: Re: problem w/plpgsql proc To: leo , pgsql-sql@postgresql.org X-Mailer: CommuniGate Pro Web Mailer v.3.4.1 Date: Mon, 15 Oct 2001 08:20:24 -0700 Message-ID: In-Reply-To: <9q74ak$5v5$1@news.tht.net> MIME-Version: 1.0 Content-Type: multipart/mixed; boundary="_===147888====davinci.ethosmedia.com===_" X-Archive-Number: 200110/192 X-Sequence-Number: 5147 This is a multi-part MIME message --_===147888====davinci.ethosmedia.com===_ Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 8bit Leo, You're gonna feel like a dork when I point it out ... > -- if the emailaddr was found, then update the record. > -- if it wasn't, then insert the new record. ^^^ SINGLE QUOTE HERE!! BAD! You can't have single quotes inside a function, especially in comments. They will be treated as the end of the function definition string. If you write the T-SQL Procedure ---> PostgreSQL function porting guide, I volunteer to edit (certifiable MS SQL DBA). You might wanna wait for 7.2, where Jan says that cursor support in PL/pgSQL functions will be added. -Josh ______AGLIO DATABASE SOLUTIONS___________________________ Josh Berkus Complete information technology josh@agliodbs.com and data management solutions (415) 565-7293 for law firms, small businesses fax 621-2533 and non-profit organizations. San Francisco --_===147888====davinci.ethosmedia.com===_ Content-Type: text/plain Content-Disposition: attachment; filename="" Content-Transfer-Encoding: base64 DQo= --_===147888====davinci.ethosmedia.com===_ Content-Type: text/plain Content-Disposition: attachment; filename="" Content-Transfer-Encoding: base64 DQo= --_===147888====davinci.ethosmedia.com===_ Content-Type: text/plain Content-Disposition: attachment; filename="" Content-Transfer-Encoding: base64 DQo= --_===147888====davinci.ethosmedia.com===_--