Oracle FAQ Your Portal to the Oracle Knowledge Grid
HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US
 

Home -> Community -> Mailing Lists -> Oracle-L -> RE: Corrected SQL Question...

RE: Corrected SQL Question...

From: Kevin Lange <klange_at_ppoone.com>
Date: Thu, 13 Mar 2003 10:35:33 -0800
Message-ID: <F001.00569555.20030313103533@fatcity.com>


Not quite random. Note that the value is field 1 of the first record is the value in field 2 in the second. It looks like they want to pair up the cities if they appear in both columns.

i.e. Since Dallas is in column 1 with Austin in Column 2 in one record, and Dallas is in Column 2 with Austin in column 1 in a seperate record, they want those records to follow each other.

Could be a cleanup effort ... duplicate but reversed data ....

-----Original Message-----
Sent: Thursday, March 13, 2003 11:55 AM
To: Multiple recipients of list ORACLE-L

Kirti,

Can you explain the required result order? It looks random to me - or like one of the "tests" we were forced to take in High School.

Tom Mercadante
Oracle Certified Professional

-----Original Message-----
Sent: Thursday, March 13, 2003 9:31 AM
To: Multiple recipients of list ORACLE-L

Okay, let me do this right this time,... (Now that I have my hot tea going;)

Here is the test data:

SQL> select c1,c2 from cp;

C1 C2
--- ---
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 14 rows selected.

SQL> Here is what is required:

C1 C2
--- ---
AUS DAL
DAL AUS
AUS HOU
HOU AUS
DAL HOU
HOU DAL
DAL LIT
LIT DAL
DAL XYZ
XYZ DAL
HOU LIT
LIT HOU
HOU XYZ
XYZ HOU I think I am clear now...
Sorry about the wrong test data earlier...

Thanks,

--

Please see the official ORACLE-L FAQ: http://www.orafaq.net
--

Author: Deshpande, Kirti
  INET: kirti.deshpande_at_verizon.com

Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).
--

Please see the official ORACLE-L FAQ: http://www.orafaq.net
--

Author: Mercadante, Thomas F
  INET: NDATFM_at_labor.state.ny.us
Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing).
--

Please see the official ORACLE-L FAQ: http://www.orafaq.net
--

Author: Kevin Lange
  INET: klange_at_ppoone.com
Fat City Network Services    -- 858-538-5051 http://www.fatcity.com
San Diego, California        -- Mailing list and web hosting services
---------------------------------------------------------------------
To REMOVE yourself from this mailing list, send an E-Mail message to: ListGuru_at_fatcity.com (note EXACT spelling of 'ListGuru') and in the message BODY, include a line containing: UNSUB ORACLE-L (or the name of mailing list you want to be removed from). You may also send the HELP command for other information (like subscribing). Received on Thu Mar 13 2003 - 12:35:33 CST

Original text of this message

HOME | ASK QUESTION | ADD INFO | SEARCH | E-MAIL US