Date Only / Time Only

0

Please login or register to vote for this query.

(click on this box to dismiss)

Craft CMS Meta

Q&A about the site for administrators, end users, developers and designers for Craft CMS

--Date Only
SELECT CONVERT(VARCHAR(10), '2005-06-01 15:37:30.087', 101)

--Time Only
SELECT LTRIM(RIGHT(CONVERT(VARCHAR(20), GETDATE(), 100), 7))

Enter Parameters

Options:
Switch to main site
loading Hold tight while we fetch your results