Results 1 to 3 of 3

Thread: order by issue

  1. #1
    Join Date
    Apr 2007
    Posts
    9

    Unanswered: order by issue

    We executed a dynamic SQL statement (not a complex one) and we have an order by clause at the end of it. This statement does a join of 2 tables. The strange thing is that the order by seem like it doesn't work. The results are not in sequential order.
    If we were to do a straight select on just one table (for which we are doing the order by on) everything is ok.

    Has anyone experienced this before?

  2. #2
    Join Date
    Apr 2002
    Location
    Toronto, Canada
    Posts
    20,002
    Quote Originally Posted by bustacap
    Has anyone experienced this before?
    never

    tip: it might be a good idea to show the query that is misbehaving
    rudy.ca | @rudydotca
    Buy my SitePoint book: Simply SQL

  3. #3
    Join Date
    Apr 2007
    Posts
    9
    Thanks. This is my first post on the forum. I guess it shows?

    We figured it out. We forgot to put some \'s at the end of last few rows to indicate that the SQL continues on the next line. So it never got to the sort option. Ah... it's Friday.

Posting Permissions

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