X-Original-To: pgsql-sql-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id 09E2A9DC9D1 for ; Wed, 11 Jan 2006 14:00:17 -0400 (AST) Received: from postgresql.org ([200.46.204.71]) by localhost (av.hub.org [200.46.204.144]) (amavisd-new, port 10024) with ESMTP id 27603-09 for ; Wed, 11 Jan 2006 14:00:15 -0400 (AST) X-Greylist: delayed 00:05:12.76852 by SQLgrey- Received: from resmta03.ono.com (smtp.ono.com [62.42.230.12]) by postgresql.org (Postfix) with ESMTP id 768869DC98E for ; Wed, 11 Jan 2006 14:00:12 -0400 (AST) Received: from Zeus (84.120.5.248) by resmta03.ono.com (7.2.052) id 43C1E4D4000401B8 for pgsql-sql@postgresql.org; Wed, 11 Jan 2006 18:54:58 +0100 From: "Mauricio Fernandez A." To: Subject: Unable to identify an ordering operator '<' for type 'smallint[]' Date: Wed, 11 Jan 2006 18:55:01 +0100 Message-ID: MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 8bit X-Priority: 3 (Normal) X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook IMO, Build 9.0.2416 (9.0.2910.0) X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2900.2180 Importance: Normal X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=1.919 required=5 tests=[DNS_FROM_RFC_ABUSE=0.479, DNS_FROM_RFC_POST=1.44] X-Spam-Score: 1.919 X-Spam-Level: * X-Archive-Number: 200601/41 X-Sequence-Number: 23830 Hello I have been working in a report based on the query bellow. It works fine in my development server which is postgres 8.0 but in production I have postgres 7.3 and I am getting the following error: SQL Error : ERROR: Unable to identify an ordering operator '<' for type 'smallint[]' Use an explicit ordering operator or modify the query In declaration: select ac.idanalisis, ac.idpt, pt.codigohospital, ct.nombre as nombrehospital, pt.codigomedico, m.nombre || ' ' || m.apellidos as nombremedico, ac.pacact, ac.potencialpacientes, ac.planvisitas from plannegocio.analisiscliente ac inner join plannegocio.planterritorio pt on ac.idpt = pt.idpt inner join centrotrabajo ct on pt.codigohospital = ct.codigo inner join medico m on pt.codigomedico = m.codigo where ac.idpt in (select pt.idpt from plannegocio.planterritorio pt where pt.idplan = 1) group by ac.idanalisis, ac.idpt, pt.codigohospital, ct.nombre, pt.codigomedico, nombremedico, ac.pacact, ac.potencialpacientes, ac.planvisitas order by ct.nombre, nombremedico The only strange thing in the query is that ac.potencialpacientes is smallint[] (in fact is the only thing with sense I can see in the error message) but I am not using the '<' operator as it suggest. Can somebody help me?. thanks in advance Mauricio Fernández A. Ingeniero de Sistemas U. Autónoma de Manizales