Saturday, October 5, 2013

Differences Between a View and a Stored Procedure SQL SERVER

View
---------------------
View is a Logical way of Looking at the data that is located in the Physical table. View Contains Only the definition but not the Data.
View Contains only the Select Statement. CREATE,INSERT,UPDATE,DELETE and TRUNCATE Statements are not Allowed.
Views does not Contain any Parameters.
Views does not Contain ‘Select Into’, ‘Group By’ , ‘Order By’ and ‘Having’.


Stored Procedure
---------------------
Stored Procedure is a database object which can used to move the data from the application to the Backend enforcing the Business Rules.
In addition to the Select statement, Stored Procedure contains all the DML statements like INSERT,UPDATE,DELETE and TRUNCATE Statements.
Stored Procedure can contain three types of Parameters IN, OUT and INOUT.
Stored Procedure can have  the clauses like  ‘Group By’ ,’Order By’, ’Having’

No comments:

Post a Comment

Opps Part 1 : Abstraction

  Abstraction in C# is a fundamental concept of object-oriented programming (OOP) that allows developers t...