Received: from magus.postgresql.org ([87.238.57.229]) by malur.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TOLgO-00041f-5K for pgsql-jdbc@postgresql.org; Wed, 17 Oct 2012 04:56:40 +0000 Received: from mail-pb0-f46.google.com ([209.85.160.46]) by magus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1TOLgH-0004HP-Mx for pgsql-jdbc@postgresql.org; Wed, 17 Oct 2012 04:56:39 +0000 Received: by mail-pb0-f46.google.com with SMTP id rr4so6726569pbb.19 for ; Tue, 16 Oct 2012 21:56:31 -0700 (PDT) X-Google-DKIM-Signature: v=1; a=rsa-sha256; c=relaxed/relaxed; d=google.com; s=20120113; h=message-id:date:from:user-agent:mime-version:to:cc:subject :references:in-reply-to:content-type:content-transfer-encoding :x-gm-message-state; bh=w/RkI25l0tBns4pT4I1GsUilLxDayuYb1ATRHPgdTeo=; b=i3d10Xeey5wcOwz+0C1UdkNl/tuzb/l5zMDB7A3J1tczZTHsJdpbQKssGB7EKfIDw5 ehW6suCvzs8g4r2BhwpkDxpTtPJm2ogx8zqfy6Udm4VrUyTcYgYApnTjg8ZFG0rwMNBM G25xmis79JkloVryV50FYHzKxT5ICy6rGd5FbbqpU2CzgamXH0i8Q+W5LaH88zCLn0po Z3G1+qXatPAKF3UtxbiTy4gCGF4EgXM8beps9Rw10ZZtLwWE32/neJyivmMGbO893dqA 5icaxtROP1UIhQbAh+9mvsY3JGFCMmygXnGsW1U2Tuqf7KtoZoqIbAwmpnTzzZJo6DW+ VIRg== Received: by 10.68.237.106 with SMTP id vb10mr52719430pbc.112.1350449790943; Tue, 16 Oct 2012 21:56:30 -0700 (PDT) Received: from ayaki.localdomain (office1.postnewspapers.com.au. [150.101.171.128]) by mx.google.com with ESMTPS id pl2sm6388661pbb.66.2012.10.16.21.56.26 (version=SSLv3 cipher=OTHER); Tue, 16 Oct 2012 21:56:29 -0700 (PDT) Message-ID: <507E3A78.5040707@ringerc.id.au> Date: Wed, 17 Oct 2012 12:56:24 +0800 From: Craig Ringer User-Agent: Mozilla/5.0 (X11; Linux x86_64; rv:14.0) Gecko/20120717 Thunderbird/14.0 MIME-Version: 1.0 To: Dave Cramer CC: Luis Flores , Thomas Kellerer , "pgsql-jdbc@postgresql.org" Subject: Re: bug report: slow getColumnTypeName References: <50745541.8060204@ttc-cmc.net> <50776FB4.5090701@ringerc.id.au> <5077C103.4040701@ringerc.id.au> <5077EBAD.5060708@ringerc.id.au> In-Reply-To: Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Gm-Message-State: ALoCoQmojU/BhuPLAZml7RZpsxBiwcB7XHObjiwWO39nvjJylFdz6H+MNQjViD74re3szAY+Lt8S X-Pg-Spam-Score: -1.9 (-) X-Archive-Number: 201210/66 X-Sequence-Number: 23390 On 10/17/2012 07:28 AM, Dave Cramer wrote: > So what is the consensus on this. > > I would lean towards removing serial types here I certainly want to, as I think the status quo is not only inefficient and incorrect but it fails to even function as designed (incorrectly calling 'integer' columns generated by a sequence 'serial' no matter what the sequence is) and cannot easily be fixed. The questions that must still be answered are: - How do we tell developers about the change? - Is a compatibility flag required? - What might it break? Do we need to test popular ORM systems or let their developers know? - What does the metadata spec actually require us to supply? The 9.2 driver has been pushed and it's a backwards-incompatible change, so it's probably a change that's only suitable for 9.3/master. I'm inclined to just make the change in master, push a beta driver to the website, and see it reports come in. I can test Hibernate and EclipseLink out, but I'm pretty sure they won't care. BTW, I'm quite surprised that PostgreSQL doesn't expose information about column value generation in INFORMATION_SCHEMA.COLUMNS at the moment; the "is_identity" column is always "NO" and "is_generated" is always "NEVER". `pg_attribute` doesn't seem to convey it either. Shouldn't we be able to ask PostgreSQL for this information? I'll have a look and see how the driver currently reports whether fields are generated, are identity fields, etc. Looking at the number of issue reports that focus on metadata, I suspect that's a real weak point of the current driver and really needs a review. Yay. Something for all that abundant spare time. -- Craig Ringer