Received: from maia.hub.org (maia-2.hub.org [200.46.204.251]) by mail.postgresql.org (Postfix) with ESMTP id 93C83B5DC1E for ; Wed, 12 Oct 2011 11:50:26 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.251]) (amavisd-maia, port 10024) with ESMTP id 16634-01 for ; Wed, 12 Oct 2011 14:50:20 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.8.0-rc2 Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by mail.postgresql.org (Postfix) with ESMTP id 4CC4CB5DC1F for ; Wed, 12 Oct 2011 11:50:20 -0300 (ADT) Received: from sss2.sss.pgh.pa.us (tgl@localhost [127.0.0.1]) by sss.pgh.pa.us (8.14.2/8.14.2) with ESMTP id p9CEoHkS013390; Wed, 12 Oct 2011 10:50:17 -0400 (EDT) To: Andrew Dunstan cc: Robert Haas , Magnus Hagander , Heikki Linnakangas , Stefan Kaltenbrunner , PostgreSQL Subject: Re: [BUGS] *.sql contrib files contain unresolvable MODULE_PATHNAME In-reply-to: <4E95A4BE.8050501@dunslane.net> References: <20111012075314.GA25470@piware.de> <4E954895.6040701@kaltenbrunner.cc> <4E95523E.1010608@enterprisedb.com> <12966.1318428759@sss.pgh.pa.us> <4E95A4BE.8050501@dunslane.net> Comments: In-reply-to Andrew Dunstan message dated "Wed, 12 Oct 2011 10:31:26 -0400" Date: Wed, 12 Oct 2011 10:50:17 -0400 Message-ID: <13389.1318431017@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-2.404 tagged_above=-5 required=5 tests=BAYES_00=-1.9, RP_MATCHES_RCVD=-0.504 X-Spam-Level: X-Archive-Number: 201110/713 X-Sequence-Number: 196519 Andrew Dunstan writes: > *shrug* ok. Another thought I had was to have the file raise an error > and have that filtered out by the extension mechanism. But I'm not sure > if it's worth the trouble. Hmm ... \echo You should use CREATE EXTENSION foo to load this file! and teach CREATE EXTENSION to drop any line beginning with \echo? The latter part seems easy enough, but I'm not quite sure about the wording or placement of the \echo command. Putting it at the top feels natural but the message might scroll offscreen due to errors... regards, tom lane