Received: from makus.postgresql.org (makus.postgresql.org [98.129.198.125]) by mail.postgresql.org (Postfix) with ESMTP id 8C70A171224E for ; Tue, 6 Mar 2012 15:09:29 -0400 (AST) Received: from plane.gmane.org ([80.91.229.3]) by makus.postgresql.org with esmtp (Exim 4.72) (envelope-from ) id 1S4zlI-0000Cf-GS for pgsql-jdbc@postgresql.org; Tue, 06 Mar 2012 19:09:29 +0000 Received: from list by plane.gmane.org with local (Exim 4.69) (envelope-from ) id 1S4zl3-0002Dq-7B for pgsql-jdbc@postgresql.org; Tue, 06 Mar 2012 20:09:13 +0100 Received: from ppp-188-174-75-120.dynamic.mnet-online.de ([188.174.75.120]) by main.gmane.org with esmtp (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 06 Mar 2012 20:09:13 +0100 Received: from spam_eater by ppp-188-174-75-120.dynamic.mnet-online.de with local (Gmexim 0.1 (Debian)) id 1AlnuQ-0007hv-00 for ; Tue, 06 Mar 2012 20:09:13 +0100 X-Injected-Via-Gmane: http://gmane.org/ To: pgsql-jdbc@postgresql.org From: Thomas Kellerer Subject: Driver does not return comments for types Date: Tue, 06 Mar 2012 20:09:08 +0100 Lines: 17 Message-ID: Mime-Version: 1.0 Content-Type: text/plain; charset=ISO-8859-15; format=flowed Content-Transfer-Encoding: 7bit X-Complaints-To: usenet@dough.gmane.org X-Gmane-NNTP-Posting-Host: ppp-188-174-75-120.dynamic.mnet-online.de User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.1; de; rv:1.8.1.21) Gecko/20090302 Thunderbird/2.0.0.21 Mnenhy/0.7.5.666 X-Pg-Spam-Score: -1.9 (-) X-Archive-Number: 201203/5 X-Sequence-Number: 22744 Hello, when defining a comment on a type like this: create type footype as (id integer); comment on type footype is 'foobar'; The driver will not return the comment in the remarks column when calling DatabaseMetaData.getTables() The reason for this is, that AbstractJdbc2DatabaseMetaData joins pg_class against pg_description which is not correct for types as far as I can tell. For types pg_description must be joined against pg_type (using pg_type.oid = pg_description.objid) Not sure what the best method to integrate this into the statement used by getTables() would be though. Regards Thomas