Click here to Skip to main content
15,886,026 members
Please Sign up or sign in to vote.
2.00/5 (2 votes)
Guys,

Really need your suggestions for improvisaton in performance of MVC application as well as SQL-Server2012 database.

SQLServer database is approx 5TB and webapplicaton is running slow. We have done optimization but still need your guidance for improving speed on both web & db.
DB having Masters table, transactions tables and also using for reports.

How Split Database will be helpful for improvisation??

Appreciate your help!

Thanks,

What I have tried:

Normalization, Index, Query Optimization.
Posted
Updated 22-Sep-19 2:24am

1 solution

The app isn't necessarily running slow, but the queries might be. Honestly, there's nothing we can do for you without seeing the schema, and all the code.

Some advice I can give is (in no particular order):

0) Avoid calling user-defined functions from a query. That is a TRUE performance killer.

1) Avoid using ORDER BY in the query itself. The larger the returned data set is, the more of a performance hit you see. Your web app should do the sorting with Ling.

2) Avoid using Entity Framework. EF takes three times longer to do stuff than a home-grown bare metal DAL. This is the way we do it, and we deal with millions of records at a time with almost instantaneous response from the database.

3) Reduce the amount of data you're returning from each query.

4) Evaluate each query's performance plan in SSMS to make sure they're performing as fast as possible.

5) Avoid calling ANY SQL function in your queries. We had dates stored as strings, which required us to cast them to a datetime in order to perform date math with them. When we removed that need, the query performance increased by 25%.
 
Share this answer
 
Comments
Freelancers 16-Jun-21 4:29am    
Thanks for the reply!
Freelancers 16-Jun-21 4:29am    
Thanks for the reply!

This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)



CodeProject, 20 Bay Street, 11th Floor Toronto, Ontario, Canada M5J 2N8 +1 (416) 849-8900