Received: from localhost (unknown [200.46.204.184]) by postgresql.org (Postfix) with ESMTP id DE9339F9245 for ; Fri, 9 Nov 2007 16:47:10 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.204.184]) (amavisd-maia, port 10024) with ESMTP id 59569-05-4 for ; Fri, 9 Nov 2007 16:46:51 -0400 (AST) Received: from nf-out-0910.google.com (nf-out-0910.google.com [64.233.182.185]) by postgresql.org (Postfix) with ESMTP id 07C639F9605 for ; Fri, 9 Nov 2007 16:47:03 -0400 (AST) Received: by nf-out-0910.google.com with SMTP id f5so477915nfh for ; Fri, 09 Nov 2007 12:47:01 -0800 (PST) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=beta; h=domainkey-signature:received:received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; bh=Ocpdf/FTow9q9jbrsHqhrBWNmfFtYpUBFKlEFOL8gvs=; b=X6eE0wbbriczLrzQvhh7rpV86D+5JUE9/SRllkNBxYsvIBW4mow6bR9edYpb+JgcESG0vzZoeeoXwydE/s61mSGJOALpJDI0yCJXfZAU59GAvCeO0GumE0IwHIapxa8wedRXrtJf4NWvU3OhLVnNOdE2BSnjtgcPDQofIBgN4fg= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=beta; h=received:message-id:date:from:to:subject:cc:in-reply-to:mime-version:content-type:content-transfer-encoding:content-disposition:references; b=fOsaQylGiE/CL5/tx5b9T0TgexE51bG2s28Yig76GreDE90II5Qn71/0jq6Q2z/SrSAu3wc5M1HIDfUBxFOoTtEiXBJPwbdLCoCC4BMws2tRvHh6mOeXtWksyFGfjq/7UxhWOBQJtU9crfr8aVdiKQGvZRmpt9NddgmolyGbGKo= Received: by 10.67.29.12 with SMTP id g12mr766453ugj.1194641221155; Fri, 09 Nov 2007 12:47:01 -0800 (PST) Received: by 10.67.95.18 with HTTP; Fri, 9 Nov 2007 12:47:01 -0800 (PST) Message-ID: Date: Fri, 9 Nov 2007 14:47:01 -0600 From: "Scott Marlowe" To: "Erik Jones" Subject: Re: work_mem and shared_buffers Cc: "Campbell, Lance" , "Heikki Linnakangas" , pgsql-performance@postgresql.org In-Reply-To: <3CE40232-B0A7-4603-806A-2912CE3E99F1@myemma.com> MIME-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit Content-Disposition: inline References: <47349F4E.5070204@enterprisedb.com> <3CE40232-B0A7-4603-806A-2912CE3E99F1@myemma.com> X-Virus-Scanned: Maia Mailguard 1.0.1 X-Archive-Number: 200711/157 X-Sequence-Number: 27572 On Nov 9, 2007 2:38 PM, Erik Jones wrote: > > > > > I imagine in a few years, hardly anyone using postgresql will remember > > the ancient art of having either apostrophes in a row inside your > > plpgsql functions... > > Speaking of that devil, I started working with Postgres mere months > after that particular evil went away but we still have a good bit of > plpgsql with it in production. I've been meaning to convert it and > clean it up for a while now. Would you, or anybody, happen to know > of any scripts out there that I could grab to make a quick job, no > brains required of it? Man, I can't think of any. I'd assume you'd need to look for the longest occurance of ' marks, and replace it with one field, say $1$ or something, then the next smaller set, with $2$ or something and so on. I imagine one could write a script to do it. Luckily, we only had one or two levels of ' marks in any of our stored procs, so it was only a few minutes each time I edited one to switch it over.