Received: from merganser.its.uu.se (merganser.its.uu.se [130.238.6.236]) by hub.org (8.10.1/8.10.1) with ESMTP id e6802SW40142 for ; Fri, 7 Jul 2000 20:02:29 -0400 (EDT) Received: from regulus.student.UU.SE ([130.238.5.2]:64546 "EHLO regulus.its.uu.se") by merganser.its.uu.se with ESMTP id ; Sat, 8 Jul 2000 02:01:45 +0200 Received: from peter (helo=localhost) by regulus.its.uu.se with local-esmtp (Exim 3.02 #2) id 13AiB5-0006Ac-00; Sat, 08 Jul 2000 02:09:03 +0200 Date: Sat, 8 Jul 2000 02:09:02 +0200 (CEST) From: Peter Eisentraut To: Thomas Swan cc: pgsql-sql@postgresql.org Subject: Re: Altnerate Column Return Names In-Reply-To: <4.3.2.7.2.20000707083729.01ff2f08@sunset.backbone.olemiss.edu> Message-ID: MIME-Version: 1.0 Content-Type: TEXT/PLAIN; charset=ISO-8859-1 Content-Transfer-Encoding: 8BIT X-Archive-Number: 200007/87 Thomas Swan writes: > If I do a select * from table1, table2 where table1.id = table2.id I > normally get two columns returned with a column identifier of id. > id | name | data | id | name | data > ----+------+------+----+------+------ > Is there anyway to get the result to return > > table1.id | table1.name | table1.data | table2.id | ,,, > -----------+-------------+-------------+-----------+- ... select table1.id as "whatever you want", table1.name as "whatever you want", table1.data as "something", ... You get the idea. -- Peter Eisentraut Sernanders väg 10:115 peter_e@gmx.net 75262 Uppsala http://yi.org/peter-e/ Sweden