SQL Error

5 pts.
Tags:
SQL
SQL error messages
we need to determine error message:the condition applied to this collectioncontains an ORDER BY without a corresponding TOP clause.

Answer Wiki

Thanks. We'll let you know when a new response is added.

I suppose that you use ORDER BY in a subquery.
This is not admitted without use of TOP clause (SQL Server).
If you need all rows from subquery, you can use this trick

<pre>SELECT TOP 100 PERCENT

ORDER BY
… </pre>

Discuss This Question: 2  Replies

 
There was an error processing your information. Please try again later.
Thanks. We'll let you know when a new response is added.
Send me notifications when members answer or reply to this question.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy
  • carlosdl
    More details are needed to answer. What database are you using ? Can you post the query or instruction that is generating the error ?
    69,065 pointsBadges:
    report
  • Meandyou
    please also post the EXACT error message and the error code or error number.
    5,220 pointsBadges:
    report

Forgot Password

No problem! Submit your e-mail address below. We'll send you an e-mail containing your password.

Your password has been sent to:

To follow this tag...

There was an error processing your information. Please try again later.

REGISTER or login:

Forgot Password?
By submitting you agree to receive email from TechTarget and its partners. If you reside outside of the United States, you consent to having your personal data transferred to and processed in the United States. Privacy

Thanks! We'll email you when relevant content is added and updated.

Following