select convert (varchar(20),getdate(),20)
output result
2011-03-08 16:53:04
select convert (varchar(20),getdate(),21)
output result
2011-03-08 17:04:09.
select convert (varchar(20),getdate(),22)
output result
03/08/11 5:04:42 PM
select convert (varchar(20),getdate(),23)
output result
2011-03-08
select convert (varchar(20),getdate(),24)
output result
17:05:51
select convert (varchar(20),getdate(),25)
output result
2011-03-08 17:06:16.
select convert (varchar(20),getdate(),100)
output result
Mar 8 2011 4:54PM
select convert (varchar(20),getdate(),101)
output result
03/08/2011
select convert (varchar(20),getdate(),102)
output result
2011.03.08
select convert (varchar(20),getdate(),103)
output result
08/03/2011
select convert (varchar(20),getdate(),104)
output result
08.03.2011
select convert (varchar(20),getdate(),105)
output result
08-03-2011
select convert (varchar(20),getdate(),106)
output result
08 Mar 2011
select convert (varchar(20),getdate(),107)
output result
Mar 08, 2011
select convert (varchar(20),getdate(),108)
output result
17:00:33
select convert (varchar(20),getdate(),109)
output result
Mar 8 2011 5:01:09
select convert (varchar(20),getdate(),110)
output result
03-08-2011
select convert (varchar(20),getdate(),111)
output result
2011/03/08
select convert (varchar(20),getdate(),112)
output result
20110308
select convert (varchar(20),getdate(),113)
output result
08 Mar 2011 17:03:06
select convert (varchar(20),getdate(),114)
output result
17:03:31:553