Click here to Skip to main content
15,905,419 members
Please Sign up or sign in to vote.
1.00/5 (1 vote)
HI Frds Good Afternoon to Everyone,
I am Creating a small Windows Application using C# .net...Whether i can write sql query directly or by using Stored Procedure...What is diiference of them...Advantages and disadvantages
Posted

1 solution

Always talk to a SQL server with Stored Procedures ... It has the following advantages

1. Security is much easier to control
2. You hide the underlying data layout, which means you can change it
3. A lot of business logic can be implemented in the SP; you get a separation of concerns
4. SQL will automatically optimise itself based on the SP

and no disadvantages that i've ever really experienced
 
Share this answer
 
Comments
itsureshuk 16-Jun-12 4:51am    
Thanks by Suresh

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