Enjoy an ad free experience by logging in. Not a member yet? Register.
Results 1 to 3 of 3
Thread: Stored functions
03-01-2013, 11:09 AM #1
- Join Date
- Sep 2012
- Thanked 0 Times in 0 Posts
Hello, of late I've been learning about stored functions. Just have one question on them please. When and how do you decide if a query is a possible candidate to become a stored function? Is it when you have a fairly large query, or when you are performing a lot of multiple operations within a query - or even something else?
03-01-2013, 05:19 PM #2
- Join Date
- Dec 2005
- Thanked 76 Times in 76 Posts
None of those.
1.When you need to do more queryies at once
2. when you dont need a resultset (if you do ,use stored procedure)
3. when you reached limit of relational db querying --> you need to parse resultset
4. when you decide to be better to have most of things done on db side, not on client side.
03-01-2013, 06:14 PM #3
I think perhaps Oatley is confused about the difference between stored functions and stored procedures.
Oatley: Bubikol was answering *specifically* about stored functions. Most people will find more uses for stored procedures than for stored functions.
An optimist sees the glass as half full.
A pessimist sees the glass as half empty.
A realist drinks it no matter how much there is.