62,268
社区成员
发帖
与我相关
我的任务
分享
select Right(1000000+day('2011-01-02'),6) UNION ALL
select Right(100000+day('2011-01-02'),5) UNION ALL
select Right(10000+day('2011-01-02'),4) UNION ALL
select Right(1000+day('2011-01-02'),3) UNION ALL
select Right(10+day('2011-01-02'),1)
select Right(100+day('2011-01-02'),2)
SELECT 天数=DATENAME(DD,GETDATE())
SELECT 月份=DATENAME(MM,GETDATE())
月份
------------------------------
05
(1 行受影响)
天数
------------------------------
28
(1 行受影响)
select 月份='0'+ rtrim(DATEPART(M,GETDATE()))
月份
-------------
05
(1 行受影响)