Function
- Should return at least one output parameter, it can return more than one parameter using OUT argument
- Parsed and compiled at runtime
- Cannot affect the state of database
- Can be invoked from SQL statement eg. SELECT fnname()
- functions are mainly used to compute values
- Doesnot return value but can return value (by OUT parameter)
- Stored as Psedo-code in database i.e complied form
- Can affect the state of database using committ etc
- Cannot be invoked from SQL statement ex. SELECT
- procedures are mainly used to process the task
No comments:
Post a Comment