Received: from maia.hub.org (maia-5.hub.org [200.46.204.29]) by mail.postgresql.org (Postfix) with ESMTP id 69869B5DC44 for ; Thu, 28 Jul 2011 17:37:20 -0300 (ADT) Received: from mail.postgresql.org ([200.46.204.86]) by maia.hub.org (mx1.hub.org [200.46.204.29]) (amavisd-maia, port 10024) with ESMTP id 33707-02-4 for ; Thu, 28 Jul 2011 20:37:14 +0000 (UTC) X-Greylist: from auto-whitelisted by SQLgrey-1.7.6 Received: from sss.pgh.pa.us (sss.pgh.pa.us [66.207.139.130]) by mail.postgresql.org (Postfix) with ESMTP id DF0E1B5DC4D for ; Thu, 28 Jul 2011 17:37:13 -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 p6SKbBUI005005; Thu, 28 Jul 2011 16:37:11 -0400 (EDT) To: Wells Oliver cc: "pgsql-admin@postgresql.org" Subject: Re: Unique operator error w/ concatenation In-reply-to: <7E1773C5-185E-48FB-B6DC-FED4DD19D317@padres.com> References: <7E1773C5-185E-48FB-B6DC-FED4DD19D317@padres.com> Comments: In-reply-to Wells Oliver message dated "Thu, 28 Jul 2011 20:19:24 -0000" Date: Thu, 28 Jul 2011 16:37:10 -0400 Message-ID: <5004.1311885430@sss.pgh.pa.us> From: Tom Lane X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=-3.093 tagged_above=-10 required=5 tests=BAYES_00=-1.9, RP_MATCHES_RCVD=-1.193 X-Spam-Level: X-Archive-Number: 201107/200 X-Sequence-Number: 37979 Wells Oliver writes: > Folks, experiencing an odd issue. The following on an 8.4 server: select 'foo'::text || 123 > Blows up, saying: > ERROR: operator is not unique: text || integer > LINE 1: select 'fo'::text || 123; > ^ > HINT: Could not choose a best candidate operator. You might need to add explicit type casts. > But on another postgres 8.4 server, it properly returns a concatenated string. > Any tips on how/where I can track down why/where there might be duplicate operators? psql's "\do ||" might help. Presumably somebody's stuck a user-defined operator named || into that database ... regards, tom lane