Received: from localhost (postgresql.org [64.49.215.8]) by postgresql.org (Postfix) with ESMTP id CB183475F4F for ; Thu, 17 Oct 2002 18:50:00 -0400 (EDT) Received: from davinci.ethosmedia.com (davinci.ethosmedia.com [209.10.40.250]) by postgresql.org (Postfix) with ESMTP id 332F9475EEE for ; Thu, 17 Oct 2002 18:50:00 -0400 (EDT) Received: from [216.135.165.74] (account ) by davinci.ethosmedia.com (CommuniGate Pro WebUser 3.5.9) with HTTP id 1790482; Thu, 17 Oct 2002 15:50:47 -0700 From: "Josh Berkus" Subject: Re: Messy Casts, Is there a better way? To: Larry Rosenman , Peter Eisentraut Cc: pgsql-sql@postgresql.org X-Mailer: CommuniGate Pro Web Mailer v.3.5.9 Date: Thu, 17 Oct 2002 15:50:47 -0700 Message-ID: In-Reply-To: <1034886179.398.17.camel@lerlaptop.iadfw.net> MIME-Version: 1.0 Content-Type: text/plain; charset="ISO-8859-1" Content-Transfer-Encoding: 8bit X-Virus-Scanned: by AMaViS new-20020517 X-Archive-Number: 200210/199 X-Sequence-Number: 9916 Larry, > If I do that, and enter '72 months' in the contract_term field, how > can > I convince PostgreSQL to output the interval back in months? It > wants > to give me '5 Years'. That's on the TODO list, I'm afraid. From the sound of it, you should stick with your current schema and custom function. -Josh Berkus