asp.net - Which is better: to sort results at the database level or at the application level -


suppose have page in site displays records database.

we need display records sorted column.

which approach gives better performance: retreive data sorted database or apply sorting on grid ?

thanks

that depends on amount of data want display. few records can shown on 1 page , sure remain constant can sorted on ui side.

for large data, sorting @ database better. if ui has pagination support, sorting @ database side avoid passing huge data ui , ui discarding rows except related first page.


Comments

Popular posts from this blog

windows - Why does Vista not allow creation of shortcuts to "Programs" on a NonAdmin account? Not supposed to install apps from NonAdmin account? -

c++ - How do I get a multi line tooltip in MFC -

asp.net - In javascript how to find the height and width -