Received: from maia.hub.org (maia-3.hub.org [200.46.204.243]) by mail.postgresql.org (Postfix) with ESMTP id CF157B600C1 for ; Thu, 2 Jun 2011 11:42:45 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.243]) (amavisd-maia, port 10024) with ESMTP id 74718-02; Thu, 2 Jun 2011 14:42:38 +0000 (UTC) X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 X-Greylist: domain auto-whitelisted by SQLgrey-1.7.6 Received: from mail-pz0-f46.google.com (mail-pz0-f46.google.com [209.85.210.46]) by mail.postgresql.org (Postfix) with ESMTP id 66EF5B6080A; Thu, 2 Jun 2011 11:42:38 -0300 (ADT) Received: by pzk9 with SMTP id 9so417027pzk.19 for ; Thu, 02 Jun 2011 07:42:38 -0700 (PDT) DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=gmail.com; s=gamma; h=domainkey-signature:mime-version:in-reply-to:references:date :message-id:subject:from:to:cc:content-type :content-transfer-encoding; bh=sxTdx8OqMEnnMJ/kYUVvAuq3BvWcpznHcNjIhUxmJu4=; b=rbGYCkxpYBK8DFaZ8Ruk0s4LIQPOuw9QP+AwawGsc5IAbOSV0nSbhtqHfWc58rWbke sLLtPqnPTUwUG49WNBVmm+sykXUh/R6B5GkiMm7h8EXO17DkwlvqeDhnlFYHHGP1/Kqv 7uyTqyfkcy6sb9iNTyF3ah/Itla57cTSxnyI0= DomainKey-Signature: a=rsa-sha1; c=nofws; d=gmail.com; s=gamma; h=mime-version:in-reply-to:references:date:message-id:subject:from:to :cc:content-type:content-transfer-encoding; b=bZY7XYWggNj8UNy0k+iPQeGRhUM6Kq11gfkk5DGk2nrCm01EJTrJOK2j9cllqU50Sm AnB8kwKwy1LHfWh9Xdt0ZvGQ6I12f/y3nxVCmzdGs4chmqDvkmPdkt+T343qZYT+6A3l fjNBZn0sAzCFn/F5bwG4U2aoGjJVMl+DESHZc= MIME-Version: 1.0 Received: by 10.68.52.105 with SMTP id s9mr320219pbo.245.1307025757715; Thu, 02 Jun 2011 07:42:37 -0700 (PDT) Received: by 10.68.56.70 with HTTP; Thu, 2 Jun 2011 07:42:37 -0700 (PDT) In-Reply-To: <14930.1307025118@sss.pgh.pa.us> References: <26909.1306965898@sss.pgh.pa.us> <27741.1306968830@sss.pgh.pa.us> <20110602.080816.460114267356667394.t-ishii@sraoss.co.jp> <1306971997-sup-5549@alvh.no-ip.org> <14930.1307025118@sss.pgh.pa.us> Date: Thu, 2 Jun 2011 10:42:37 -0400 Message-ID: Subject: Re: pgpool versus sequences From: Robert Haas To: Tom Lane Cc: Alvaro Herrera , Tatsuo Ishii , mangoo , "scott.marlowe" , "Kevin.Grittner" , pgsql-hackers Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: quoted-printable X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-1.898 tagged_above=-5 required=5 tests=BAYES_00=-1.9, FREEMAIL_FROM=0.001, RFC_ABUSE_POST=0.001 X-Spam-Level: X-Archive-Number: 201106/135 X-Sequence-Number: 188848 On Thu, Jun 2, 2011 at 10:31 AM, Tom Lane wrote: > Robert Haas writes: >> On Wed, Jun 1, 2011 at 7:47 PM, Alvaro Herrera >> wrote: >>> Yeah -- why is LOCK SEQUENCE foo_seq not allowed? =A0Seems a simple thi= ng >>> to have. > >> It cause a grammar conflict. > > That's a lot of work for a purely cosmetic issue, though. =A0What would b= e > trivial is to let this work: > > regression=3D# create sequence s1; > CREATE SEQUENCE > regression=3D# begin; > BEGIN > regression=3D# lock table s1; > ERROR: =A0"s1" is not a table > > We should do that anyway, even if we put in the effort to support the > other syntax. Ugh. We are already stuck supporting all kinds of backward compatibility cruft in tablecmds.c as a result of the fact that you used to have to use ALTER TABLE to operate on views and sequences. The whole thing is confusing and a mess. -1 from me on extending that mess to more places. --=20 Robert Haas EnterpriseDB: http://www.enterprisedb.com The Enterprise PostgreSQL Company