How many Stored Procedures created everyday ( problem in converting Datetime )?
Posted
by Space Cracker
on Stack Overflow
See other posts from Stack Overflow
or by Space Cracker
Published on 2010-05-19T05:54:47Z
Indexed on
2010/05/19
6:50 UTC
Read the original article
Hit count: 148
I make a query that return to me the count of Stored Procedure that created everyday as follow
SELECT convert(varchar, crdate, 103) as Date,Count(*) as Counter
FROM sysobjects
WHERE (xtype = 'p') AND (name NOT LIKE 'dt%')
Group by convert(varchar, crdate, 103)
and its already work but dates appear in string format that i can't order it such as below
01/03/2010 3
01/04/2008 4
01/05/2010 5
01/11/2008 1
01/12/2008 4
02/03/2008 1
02/03/2010 2
02/04/2008 4
02/05/2010 2
02/11/2008 2
02/11/2009 2
02/12/2008 4
03/01/2010 1
03/02/2010 2
03/03/2010 2
03/04/2008 2
03/04/2010 2
03/05/2008 1
03/05/2010 2
I want to make that in which date is in datetime format that i can make order by
successfully, i tried convert(datetime, crdate, 103)
but it show Full date
any idea of how to do ?
© Stack Overflow or respective owner