Stored Procedures (Database Engine)
When you create an application with Microsoft SQL Server, the Transact-SQL programming language is the primary programming interface between your applications and the Microsoft SQL Server database. When you use Transact-SQL programs, two methods are available for storing and executing the programs.
You can store the programs locally and create applications that send the commands to SQL Server and process the results.
You can store the programs as stored procedures in SQL Server and create applications that execute the stored procedures and process the results.