Title: Re: Corrected SQL Question...

SQL> select A.c1, B.c2
   2  from (select col1 c1, rownum r from tbl order by col1) A
   3  , (select col2 c2, rownum r from tbl order by col2) b
   4  where a.r = b.r
   5  union
   6  select B.c2, A.c1
   7  from (select col1 c1, rownum r from tbl order by col1) A
   8  , (select col2 c2, rownum r from tbl order by col2) b
   9  where a.r = b.r
  10  order by 1
  11  /

C1  C2
--- ---
AUS DAL
AUS HOU
DAL AUS
DAL HOU
DAL LIT
DAL XYZ
HOU AUS
HOU DAL
HOU LIT
HOU XYZ
LIT DAL
LIT HOU
XYZ DAL
XYZ HOU


At 08:19 AM 3/13/2003 -0800, you wrote:
>AUS DAL
>AUS HOU
>DAL AUS
>DAL HOU
>DAL LIT
>DAL XYZ
>HOU AUS
>HOU DAL
>HOU LIT
>HOU XYZ
>LIT DAL
>
>C1  C2
>--- ---
>LIT HOU
>XYZ DAL
>XYZ HOU

Wolfgang Breitling
Centrex Consulting Corporation
http://www.centrexcc.com


                         ********************

This email communication is intended as a private communication for the sole use of the primary addressee and those individuals listed for copies in the original message. The information contained in this email is private and confidential and if you are not an intended recipient you are hereby notified that copying, forwarding or other dissemination or distribution of this communication by any means is prohibited.  If you are not specifically authorized to receive this email and if you believe that you received it in error please notify the original sender immediately.  We honour similar requests relating to the privacy of email communications.

Cette communication par courrier électronique est une communication privée à l'usage exclusif du destinataire principal ainsi que des personnes dont les noms figurent en copie.  Les renseignements contenus dans ce courriel sont confidentiels et si vous n'êtes pas le destinataire prévu, vous êtes avisé, par les présentes que toute reproduction, tout transfert ou toute autre forme de diffusion de cette communication par quelque moyen que ce soit est interdit.  Si vous n'êtes pas spécifiquement autorisé à recevoir ce courriel ou si vous croyez l'avoir reçu par erreur, veuillez en aviser l'expéditeur original immédiatement.  Nous respectons les demandes similaires qui touchent la confidentialité des communications par courrier électronique.

Reply via email to