[freetds] Using sp_executesql with Microsoft SQL Server 2000

Lowden, James K LowdenJK at bernstein.com
Mon Jun 30 16:56:25 EDT 2003


> From: Rogers, Tom [mailto:tom.rogers at ccur.com]
> Sent: June 30, 2003 12:36 PM
> 
> However, to answer your specific question dealing with the use of
> sp_executesql for parameter passing, though I think on the 
> surface it is a
> good idea for the reasons you state, just be aware that I 
> don't think said system SP supports output parameters

Thomas, 

sp_executesql returns output parameters:

1> declare @b smallint 
   exec sp_executesql N'select @a=1', 
   N'@a int output', 
   @a=@b output 
   select @b
2> go

 ------
      1

(1 row affected)

--jkl
-----------------------------------------
The information contained in this transmission may contain privileged and confidential information and is intended only for the use of the person(s) named above. If you are not the intended recipient, or an employee or agent responsible for delivering this message to the intended recipient, any review, dissemination, distribution or duplication of this communication is strictly prohibited. If you are not the intended recipient, please contact the sender immediately by reply e-mail and destroy all copies of the original message. Please note that we do not accept account orders and/or instructions by e-mail, and therefore will not be responsible for carrying out such orders and/or instructions.





More information about the FreeTDS mailing list