Ms sql stored procedure call with date time parameter

how to call a stored procedure with a date entry.

spName getDate()

does not work.

the question is about calling sql sqs management studio.

+3
source share
1 answer

SQL Server 2008

declare @d date = getdate() /*Or datetime looking at the title*/
exec spName @d

Previous Versions

declare @d datetime
set @d = getdate()
exec spName @d
+7
source

Source: https://habr.com/ru/post/1770694/


All Articles