X-Original-To: pgsql-admin-postgresql.org@localhost.postgresql.org Received: from localhost (unknown [64.117.224.130]) by svr1.postgresql.org (Postfix) with ESMTP id 06121D1BB41 for ; Wed, 20 Aug 2003 12:21:02 -0300 (ADT) Received: from svr1.postgresql.org ([64.117.224.193]) by localhost (neptune.hub.org [64.117.224.130]) (amavisd-new, port 10024) with ESMTP id 88399-08 for ; Wed, 20 Aug 2003 12:20:51 -0300 (ADT) Received: from pns.mm.eutelsat.org (pns.mm.eutelsat.org [194.214.173.227]) by svr1.postgresql.org (Postfix) with ESMTP id 35A6BD1BA00 for ; Wed, 20 Aug 2003 12:20:50 -0300 (ADT) Received: from nts-03.mm.eutelsat.org (localhost [127.0.0.1]) by pns.mm.eutelsat.org (8.11.6/linuxconf) with ESMTP id h7KEN1710849; Wed, 20 Aug 2003 16:23:01 +0200 Received: from gmendola (gmendola.mm.eutelsat.org [194.214.173.50]) by nts-03.mm.eutelsat.org (8.11.6/linuxconf) with SMTP id h7KFG9R14356; Wed, 20 Aug 2003 17:16:09 +0200 Message-ID: <002201c3672e$68bb0770$32add6c2@mm.eutelsat.org> From: "Mendola Gaetano" To: Cc: "Rhaoni Chiu Pereira" References: <1061382268.3f43687cc3565@sistemica.info> Subject: Re: Explicit Cast Date: Wed, 20 Aug 2003 17:19:11 +0200 MIME-Version: 1.0 Content-Type: text/plain; charset="iso-8859-1" Content-Transfer-Encoding: 7bit X-Priority: 3 X-MSMail-Priority: Normal X-Mailer: Microsoft Outlook Express 6.00.2800.1158 X-MimeOLE: Produced By Microsoft MimeOLE V6.00.2800.1165 X-Virus-Scanned: by amavisd-new at postgresql.org X-Spam-Status: No, hits=0.0 tagged_above=0.0 required=5.0 tests=EMAIL_ATTRIBUTION, MSG_ID_ADDED_BY_MTA_3, QUOTED_EMAIL_TEXT, REFERENCES, REPLY_WITH_QUOTES X-Spam-Level: X-Archive-Number: 200308/223 X-Sequence-Number: 9944 "Rhaoni Chiu Pereira" wrote: > Hi List, > > As I already said .. I'm porting an Oracle DB to PostgreSQL and I must > rewrite most of the functions . So I have a problem to do something like this: > > ... atual_fatura in(''+'',''-'') ... > > It gives me the following error: > > Unable to identify an operator '-' for types 'numeric' and 'character varying' > You will have to retype this query using an explicit castenciosamente, > > atual_fatura is a varchar field. > > I read howto create an explicit cast but I didn't understand what I must do in > this case. > > Can anybody help me ? May we have more details on it ? Seems that you want add a numeric with a varchar. Regards Gaetano Mendola