+ Reply to Thread
Results 1 to 3 of 3

Thread: Order By... in a Join

  1. #1
    Guest.Visitor Guest

    Default Order By... in a Join

    What occurs to me: 1. Check the Query Optimizer messages - maybe it'll suggest an index that would work. 2. Create the resultset as a table, then sort the table. CREATE TABLE sometable AS (your sql statement) WITH DATA SELECT * FROM sometable ORDER BY somefield

  2. #2
    Guest.Visitor Guest

    Default Order By... in a Join

    Hello, I've created an SQL query that joins a few files. Everything works fine but I would like to order the resultset by a field that is one of the joined tables. When I add the "order by" clause at the end of the query, performance takes a severe hit. Basically, what I would like SQL to do is order the resultset after the resultset is created. Maybe that's not possible, but does anyone have ideas on how to get this to work?

  3. #3

    Default Order By... in a Join

    I don't have a lot of the details handy, but this can be a great help when trying to diagnose SQL performance. If you use the explain function, it will show you graphically each step used to process your SQL statement. you can get even more detail by clicking on a specific step or sometimes even just by hovering your mouse near it.

+ Reply to Thread

Similar Threads

  1. Purchase Order In Use
    By Guest.Visitor in forum General
    Replies: 2
    Last Post: 03-09-2005, 04:54 AM
  2. Sort order
    By Guest.Visitor in forum Application Software
    Replies: 2
    Last Post: 09-05-2000, 09:51 AM
  3. What do I need in order to implement SSL?
    By Guest.Visitor in forum Internet
    Replies: 1
    Last Post: 08-30-2000, 02:24 PM
  4. Pecking Order
    By frankgw@adelphia.net in forum Analysis
    Replies: 15
    Last Post: 05-26-1998, 04:51 PM

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts