hrub
Member since Dec 11, 2008
- Profile: /members/635-hrub.htm
- Comments: 2
Recent Blog Comments By hrub
-
Getting Only the Date Part of a Date/Time Stamp in SQL Server
Posted on Feb 28, 2007 at 7:58 AM
try this: (date is 24hr) declare @MyDate datetime set @MyDate = getdate() Select rtrim(datepart(hh, @MyDate)) +'h'+ Case len (datepart(mi, @MyDate)) when 1 then '0' when 2 then '' End + rtrim(datepart(mi, @MyDate)) +'m'+ rtrim(datepart(ss, @MyDate)) +'s' as 'Time'... read more »
-
Getting Only the Date Part of a Date/Time Stamp in SQL Server
Posted on Dec 21, 2006 at 6:51 AM
hi, How can i write a custom type myDate in sql 2005? -- Create the data type CREATE TYPE myDate FROM base_type,,nvarchar (precision,int,25) allow_null,,NULL I am unsure how to use this. am i looking in the right direction?... read more »