Re: When to use Stored Procedures!
From: David Gugick (davidg-nospam_at_imceda.com)
Date: 10/07/04
- Next message: David Gugick: "Re: How to do async execution"
- Previous message: TheSqlGuy: "Re: How to duplicate a row in SQL Table using a single query"
- In reply to: Anthony Judd: "When to use Stored Procedures!"
- Messages sorted by: [ date ] [ thread ]
Date: Thu, 7 Oct 2004 01:10:56 -0400
Anthony Judd wrote:
> I am still new to Sql Server & lovin' it.
>
> I'm fine for the most part with managing it and programming with
> T-SQL. One thing i lack however due to my little experience is some
> best practices protocols.
>
> One that comes to mind is when to use stored procedures and when not
> to.. For the most part i can see using SP's for everything in an
> application, not sure if that is an overkill
>
> Would love some idea of best practice when it comes to stored
> procedures.
>
> AJ
Use them exclusively, if possible. That way, you can revoke all rights
to directly access and update tables. By granting execute rights to a
stored procedure, you grant rights access tables referenced in the
procedure.
Stored procedures have other benefits as well, like resuse of execution
plans, being a part of the database itself, less roundtrips to the
server (faster performance), etc. They also come with potential problems
like recompiles.
http://msdn.microsoft.com/library/default.asp?url=/library/en-us/createdb/cm_8_des_07_31vb.asp
-- David Gugick Imceda Software www.imceda.com
- Next message: David Gugick: "Re: How to do async execution"
- Previous message: TheSqlGuy: "Re: How to duplicate a row in SQL Table using a single query"
- In reply to: Anthony Judd: "When to use Stored Procedures!"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|