Francisco H Tapia
my.lists at verizon.net
Fri Apr 11 14:11:12 CDT 2003
as this is more of a sql question, I've forwared to the dba-sqlserver list... First, I encourage you to go to microsoft's sql site and download the latest Books on line commonly known as BOL. 2nd, to declare a variable in sql server, you use the keyword "Declare" such as DECLARE varMyVariable AS VARCHAR(10) in Sql 7 you add values to the varchar by using the keyword SELECT, but in 2000 you can use the keyword SET. to step through a returned recordset from a sproc (SP) you would use a cursor, tho I will warn you that they can take a lot of time and are usually not as efficient as other means (ie, memory, cleanup, etc) , think #Temp Tables if you really need to step through things, you'll find that things can be done sooooo much faster this way... any other questions reguarding SP's feel free to post to the dba-SqlServer list :D -Francisco http://rcm.netfirms.com On Friday, April 11, 2003 11:36 AM [GMT-8], Tom Adams <tomadatn at bellsouth.net> wrote: : I've got a few very basic questions for Sql 7 stored procedures. : I've gone through all my saved AccessD's twice and can't figure it : out. I've left my main reference books at home and have 3 more : coming as we type. : : 1. How to declare variables in SP. I con't want to return them, : just use them further into the SP. : 2. How to gen a recordset or SP equvalent and step through it. : : Thanks - Tom : : _______________________________________________ : AccessD mailing list : AccessD at databaseadvisors.com : http://databaseadvisors.com/mailman/listinfo/accessd : Website: http://www.databaseadvisors.com