View Single Post
  #4 (permalink)  
Old October 2nd, 2004, 12:48 AM
jemacc jemacc is offline
Friend of Wrox
 
Join Date: Nov 2003
Location: Lehigh Acres, FL, USA.
Posts: 625
Thanks: 0
Thanked 0 Times in 0 Posts
Send a message via MSN to jemacc
Default

you probably have to use something like sp_executesql

post your table columns

I can get you this far:

create proc up_parmSel_state
as
DECLARE @IntVariable INT
DECLARE @SQLString VARCHAR(50)
DECLARE @ParmDefinition VARCHAR(50)
SET @SQLString = N'SELECT * FROM state_t WHERE stateID = @stateID'
SET @ParmDefinition = N'@stateID int'
/* Execute the string. */
SET @IntVariable = 1

EXECUTE sp_executesql @SQLString, @ParmDefinition, @stateID= @IntVariable
Reply With Quote