I have a a form containing 10 drop down lists. These lists we fetch by doing 10 calls to database at the time of form load.
I want to know the performance on application as well as on Sql Server in following 2 cases. Also please suggest best approach.
- Fetch data for each of these drop down lists doing 10 requests
- Create stored proc which will fetch 10 tables and return these 10 tables on UI in a data reader to create entities (single hit)
Please suggest your views…
option 1. It is easy to maintain.
1.10 requests doesn’t cost very much
2.assume some day you want to query only five of them, you can easily combine the data parts. if you put them into one store procdure,things will be diffcult when business logic is changed.