DotNet Academy of Rajesh Rolen

Solutions by Rajesh Rolen

Order by in functions

their is a rule which i got to know before few days and i want to share with u that you cant use order by in functions....when u try to do so u will get this error..


sg 1033, Level 15, State 1, Procedure GetDataBaseDetail, Line 21
The ORDER BY clause is invalid in views, inline functions, derived tables, subqueries, and common table expressions, unless TOP or FOR XML is also specified.

so to solve this problem you will have to use 'top ' ex.- top 1000 . with query where u want to use order by cluse.

0 comments:

Post a Comment

About this blog

My Blog List

Advertise On This Site

Site Info

Advertise on this Site

To advertise on this site please mail on RajeshRolen@gmail.com

Information Source

About

Pages

Dot Net Academy

Advertis in This Area of Site

Powered by Blogger.

Followers

Search This Blog