Skip to Content
Former Member
Mar 22, 2012 at 01:23 AM

stored proc to accept parameters at prompt


How do you create a stored proc in SQL so that when run in desk you can input parameters?

I have a simple stored proc but when I create in deski always get an error saying that it expects '@DateStart'.

here is the sproc ive used:

CREATE Procedure [dbo].[sp_redempt](@DateStart Datetime,@DateEnd Datetime)


FROM redempt
WHERE = 'abc'
AND ProcessDate >= @DateStart and ProcessDate <= @DateEnd

-- running it in SQL ent mgr
exec dbo.sp_NCLredempt '01 february 2011', '28 february 2011';

can you help with the syntax I use or specify a simple stored proc using the adventure works DB that will prompt for a parameter in deski?
BO Edge XI 3.0
App server: MS Win2003 Server Standard SP2
DB server: MS Win2003 Server Standard SP2
DB on DB server: SQL 2005