X-Original-To: pgsql-jdbc-postgresql.org@localhost.postgresql.org Received: from localhost (av.hub.org [200.46.204.144]) by postgresql.org (Postfix) with ESMTP id 62BF39DCC44 for ; Wed, 8 Feb 2006 13:46:23 -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 01027-02 for ; Wed, 8 Feb 2006 13:46:17 -0400 (AST) X-Greylist: from auto-whitelisted by SQLgrey- Received: from mail.logix-tt.com (serval.logix-tt.com [213.239.221.42]) by postgresql.org (Postfix) with ESMTP id F04C29DCBE8 for ; Wed, 8 Feb 2006 13:46:15 -0400 (AST) Received: from kingfisher.intern.logix-tt.com (Mcbf1.m.pppool.de [89.49.203.241]) (using TLSv1 with cipher DHE-RSA-AES256-SHA (256/256 bits)) (No client certificate requested) by mail.logix-tt.com (Postfix) with ESMTP id 3E682244045; Wed, 8 Feb 2006 18:46:18 +0100 (CET) Received: from [127.0.0.1] (localhost [127.0.0.1]) by kingfisher.intern.logix-tt.com (Postfix) with ESMTP id 5D92A181C1AC7; Wed, 8 Feb 2006 18:34:43 +0100 (CET) Message-ID: <43EA2BB3.1090607@logix-tt.com> Date: Wed, 08 Feb 2006 18:34:43 +0100 From: Markus Schaber Organization: Logical Tracking and Tracing International AG, Switzerland User-Agent: Debian Thunderbird 1.0.7 (X11/20051017) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Kris Jurka Cc: Ryan Li , pgsql-jdbc@postgresql.org Subject: Re: oid as long type References: <20060208094744.74887.qmail@web34701.mail.mud.yahoo.com> In-Reply-To: X-Enigmail-Version: 0.93.0.0 Content-Type: text/plain; charset=ISO-8859-1 Content-Transfer-Encoding: 7bit X-Virus-Scanned: by amavisd-new at hub.org X-Spam-Status: No, score=0.12 required=5 tests=[AWL=0.120] X-Spam-Score: 0.12 X-Spam-Level: X-Archive-Number: 200602/58 X-Sequence-Number: 14655 Hi, Kris, Kris Jurka wrote: > The use of int is a historical artifact, but the problem is that we > can't change the API without requiring clients to make code changes for > some methods. We could add duplicate method signatures that take long > for the oid types, but the problem is methods like LargeObject.getOID() > and LargeObjectManager.create() return int and these cannot be changed > to long without adjustments to the calling code. Additionally changes > would be required to the fastpath infrastructure to send and receive > longs which would be complicated by the fact that oids are really > unsigned int4, not int8. > > So this is a known problem, but one we've generally avoided dealing with > because few people actually bump into it. I suppose we could add the > new method signatures and add new methods like getLongOID and only bail > out when code called the old ones with values to be to be represented by > an int. I'll put it on my todo list, but it's not real close to the top. Maybe it would be possible to map it bit-wise to a singned int, so we have negative OIDs on java side? Markus -- Markus Schaber | Logical Tracking&Tracing International AG Dipl. Inf. | Software Development GIS Fight against software patents in EU! www.ffii.org www.nosoftwarepatents.org