Powered By Blogger

Sunday 22 April 2012

Difference Between TRIGGER AND PROCEDURE


¯  Trigger Vs Procedure
                  Trigger
                   Procedure
1.   Trigger does not accept parameters.

2.   A trigger is executed implicitly by the oracle engine.
1. Procedure accepts the parameters.


2.Procedure is execute explicitly, called by a user

Difference Between FUNCTION AND PROCEDURE


Procedure Vs Function
                    Procedure
                   Function
1. Procedure doesn’t contain return clause in header & executable part.

2. Procedure may be return or may not be return a value.

3. Procedure can’t be called into select statements.

4. Procedure are used to implement business logic.
1. Function contain return clause in header & executable part.

2. Function always returns a value.


3. Function can be called into select statement.

4. Function are used for numeric calculation.

Difference Between WHERE AND HAVING


WHERE Vs HAVING
                     Where
                    Having
1.Without group by clause

2. Where clause select Row before grouping.

3. Where clause can’t contain aggregate function.
1.With group by clause

2.Having clause select after grouping


3.Having clause contain aggregate
Function.

Difference Between JOIN & UNION



Difference between JOIN and UNION
                      Join
                    Union
1.   Join the columns.

2.   Duplicate are allowed

3.   Combine the column based on condition.
1.Merge the row

2.Duplicates are not allowed

3. Combine the result of two select statements.