X-Original-To: pgsql-jdbc-postgresql.org@postgresql.org Received: from localhost (mx1.hub.org [200.46.208.251]) by postgresql.org (Postfix) with ESMTP id D0C5F9FA50F for ; Fri, 22 Sep 2006 00:56:30 -0300 (ADT) Received: from postgresql.org ([200.46.204.71]) by localhost (mx1.hub.org [200.46.208.251]) (amavisd-new, port 10024) with ESMTP id 99649-03 for ; Fri, 22 Sep 2006 00:56:22 -0300 (ADT) X-Greylist: from auto-whitelisted by SQLgrey- Received: from yass.opencloud.co.nz (yass.opencloud.co.nz [131.203.101.226]) by postgresql.org (Postfix) with ESMTP id AD4D89FA175 for ; Fri, 22 Sep 2006 00:56:21 -0300 (ADT) Received: from sony.opencloud.co.nz ([192.168.0.41]) by yass.opencloud.co.nz with asmtp (TLS-1.0:DHE_RSA_AES_128_CBC_SHA:16) (Exim 4.34) id 1GQc9D-0005b4-0O; Fri, 22 Sep 2006 15:56:19 +1200 Message-ID: <45135EE2.6020507@opencloud.com> Date: Fri, 22 Sep 2006 15:56:18 +1200 From: Oliver Jowett User-Agent: Mozilla Thunderbird 1.0.8 (X11/20060502) X-Accept-Language: en-us, en MIME-Version: 1.0 To: Philip Yarra CC: Alex Stienstra , pgsql-jdbc@postgresql.org Subject: Re: ResultSetMetaData.getTableName() == null References: <20060921121816.9wvu8sr34w5c4848@webmail.versatel.nl> <45133DE5.4030100@utiba.com> <451354B5.2070701@opencloud.com> <45135D9B.50500@utiba.com> In-Reply-To: <45135D9B.50500@utiba.com> Content-Type: text/plain; charset=ISO-8859-1; format=flowed Content-Transfer-Encoding: 7bit X-Virus-Scanned: Maia Mailguard 1.0.1 X-Spam-Status: No, hits=0.05 tagged_above=0 required=5 tests=AWL X-Spam-Level: X-Archive-Number: 200609/90 X-Sequence-Number: 15808 Philip Yarra wrote: > Oliver Jowett wrote: > >> Essentially I think it boiled down to "getTableName() should return >> the table alias name", and since we don't have that available we >> return "". There's a postgresql-specific interface to get at the >> underlying table name (in the cases where that info is available). > > > Hmmm... maybe I'm missing something, but the attached test case doesn't > use any aliases, and it returns "" (at least it does for me). Is this > expected behaviour? If there's a postgresql-specific way to get it, > couldn't this method implement the same way of getting it? We don't know whether aliases have been used or not so we can't do this. -O