what is the difference between trigger and storedprocedures

Answer Posted / sunny kumar rana

1) A stored procedure can accept parameters while a trigger
cannot.
2) A trigger can’t return any value while stored procedures
depand on condition.
3) A trigger is executed automatically on some event while
a stored procedure needs to be explicitly called.
4) Triggers are used for insertions, update and deletions
on tables while stored procedures are often using
independently in the database.
5) A trigger cannot be written in a stored procedure.
However, the reverse is not possible.

Is This Answer Correct ?    1 Yes 0 No



Post New Answer       View All Answers


Please Help Members By Posting Answers For Below Questions

What is a boolean in sql?

518


How many times can we commit in a loop?

564


What is a left inner join?

529


What is the purpose of a secondary key?

502


how to calculate the difference between two dates? : Sql dba

543






Does google use sql?

506


what is acid property in database? : Sql dba

555


What is out parameter used for eventhough return statement can also be used in pl/sql?

577


How do you use a while loop in pl sql?

532


When sql appeared?

613


What is cte sql?

513


What is a temporal table?

488


What are synonyms in sql?

530


Is primary key clustered index?

516


What is Materialized View? In What Scenario we Use Materialized View?

8508