Please start any new threads on our new site at https://forums.sqlteam.com. We've got lots of great SQL Server experts to answer whatever question you can come up with.

 All Forums
 SQL Server 2000 Forums
 SQL Server Development (2000)
 Declare DateFormat

Author  Topic 

tmaiden
Yak Posting Veteran

86 Posts

Posted - 2008-02-15 : 15:09:16
I am trying to write this dynamically prior to building case statements.

declare @interval varchar(20)
set @interval = 'minute'
select dateadd(@interval,20,getdate())


is there a way to declare a “date format”?

Michael Valentine Jones
Yak DBA Kernel (pronounced Colonel)

7020 Posts

Posted - 2008-02-15 : 15:14:27
select dateadd(minute,20,getdate())

CODO ERGO SUM
Go to Top of Page

Lamprey
Master Smack Fu Yak Hacker

4614 Posts

Posted - 2008-02-15 : 17:52:54
Maybe this would help?
http://www.sqlteam.com/forums/topic.asp?TOPIC_ID=96565
Go to Top of Page
   

- Advertisement -