Re: q:Subqueries

From: Saad Ahmad <sahmad_at_mfa.com>
Date: 1995/08/25
Message-ID: <41jb83$604_at_homer.alpha.net>#1/1


Antoine Boatwright (boatwright_at_logica.com) wrote:
> I am trying to do an insert using a subquery i.e.
> INSERT INTO table1 (field1, field2)
> SELECT field3, field 4
> FROM table2
> The problem is as follows. I would like to ORDER BY field3 but one cannot
> use the ORDER BY clause in a subquery according to the manual.

There is rarely a need to ORDER BY in this case...

Did you try putting a DISTINCT; that should cause a SORT. Or try PL/SQL.

--
**************************************************************
*                          Saad Ahmad                        *
*                          McHugh Freeman & Associates, Inc. *
*                          Ph:  (414) 798-8606 Ext. 457      *
*                          Fax: (414) 798-8619               *
*                          E-Mail: sahmad_at_mfa.com            *
**************************************************************
Received on Fri Aug 25 1995 - 00:00:00 CEST

Original text of this message