SQL Server 2008 has introduced the new Date and Time data types. Now assigning a date to time data type will return only the time part of the datetime and the Date will return the Date part of the datetime ...
DECLARE @datetime AS DATETIME = getdate();
DECLARE @date AS DATE = @datetime;
DECLARE @time AS TIME = @datetime;
SELECT @date, @datetime, @time
Result is:
2012-07-01 2012-07-01 10:40:06.403 10:40:06.4030000
Or alternatively:
SELECTCONVERT(TIME,GETDATE()) AS HourMinuteSecond,CONVERT(DATE,GETDATE()) AS DateOnly
GO
Or to get only the HH:MM then as follow:
DECLARE @time AS TIME(0) = @datetime; -- With zero precision so returns hh:mm
'via Blog this'
Popular Posts
-
Kendo UI applying SUM in footer template kendo ui - KendoUI: Grid Summary values in Footer - Stack Overflow : ", footerTemplate:...
-
MVC grid example ASP.NET MVC Flexigrid sample - CodeProject : 'via Blog this'
-
A possible way of handling distributed transaction for multiple contexts without alleviation to MSDTC??? c# - Entity Framework - Using Trans...
Saturday, June 30, 2012
SQL Complete - Intellisense in SQL Server Management Studio
An excellent sql server addin that provides code completion. SQL Complete... Freeware
SQL Complete - Intellisense in SQL Server Management Studio:
'via Blog this'
SQL Complete - Intellisense in SQL Server Management Studio:
'via Blog this'
Friday, June 29, 2012
Great deal between MS and Pluralsight.... as long as you have a windows live id and you register on websitespark website then you get 3 months of free pluralsight for free!!!
Publish Post
WebsiteSpark + Pluralsight | the pluralsight blog:
http://www.microsoft.com/web/websitespark/offers/pluralsight.aspx?WT.mc_id=ban-c-corp-loc-wss
'via Blog this'
Publish Post
WebsiteSpark + Pluralsight | the pluralsight blog:
http://www.microsoft.com/web/websitespark/offers/pluralsight.aspx?WT.mc_id=ban-c-corp-loc-wss
'via Blog this'
Tuesday, June 26, 2012
VMware Communities: Guest Windows Server 2008 64bit on Host...
Issue with installing the windows server 2008 and vmwre ... looks like some options needs to be chaned in BIOS and some settings needs to be ticked in VMWare:
VMware Communities: Guest Windows Server 2008 64bit on Host...:
'via Blog this'
VMware Communities: Guest Windows Server 2008 64bit on Host...:
'via Blog this'
Saturday, June 23, 2012
Wednesday, June 20, 2012
Adding a Client to a Server Domain - YouTube
Creating the AD forest and installing of AD and then adding AD client to the Domain.
Adding a Client to a Server Domain - YouTube:
'via Blog this'
Adding a Client to a Server Domain - YouTube:
'via Blog this'
Tuesday, June 19, 2012
Build a handy Microsoft Dynamics CRM development environment - Microsoft Dynamics CRM Team Blog - Site Home - MSDN Blogs
Setting up the CRM 2011 dev environment in one machine
Build a handy Microsoft Dynamics CRM development environment - Microsoft Dynamics CRM Team Blog - Site Home - MSDN Blogs:
'via Blog this'
Build a handy Microsoft Dynamics CRM development environment - Microsoft Dynamics CRM Team Blog - Site Home - MSDN Blogs:
'via Blog this'
Sunday, June 10, 2012
c# - StructureMap singleton usage (A class implementing two interface) - Stack Overflow
Registering more than one interface of a class with IoC contrainer:
c# - StructureMap singleton usage (A class implementing two interface) - Stack Overflow:
'via Blog this'
c# - StructureMap singleton usage (A class implementing two interface) - Stack Overflow:
'via Blog this'
Friday, June 1, 2012
RUSSELL MCCLOY: Entity validation, unit testing and MVC 3 with Fluent - RuleSets and Predicates
using fluent validation with MVC instead of EF attributes
RUSSELL MCCLOY: Entity validation, unit testing and MVC 3 with Fluent - RuleSets and Predicates:
'via Blog this'
RUSSELL MCCLOY: Entity validation, unit testing and MVC 3 with Fluent - RuleSets and Predicates:
'via Blog this'
Subscribe to:
Posts (Atom)