Reputation: 115
In a Stored Procedure, I intend to Execute the SP but have to give it the parameter date. The Stored Procedure looks like this:
[dbo].[ADM_CTM]
The parameter is set up like this:
@CurDate(smalldatetime, input, Nodefault)
In my effort, I did this:
EXEC [dbo].[ADM_CTM] @CurDate(20151001)
Please correct the Execution statement as necessary. Thank you
Upvotes: 1
Views: 832
Reputation: 172618
You can try like this:
EXEC [dbo].[ADM_CTM] @CurDate = '20151001'
Upvotes: 0
Reputation: 20509
EXEC [dbo].[ADM_CTM] @CurDate = '20151001'
Although I recommend explicitly specifying the month, so as to not encounter date format issues:
EXEC [dbo].[ADM_CTM] @CurDate = '01-OCT-2015'
Upvotes: 1