某外企SQL Server面试题
摘要:
试题点评:通览整个试题,我们不难发现,这份试题是针对SQL Server数据库人员的。而从难度分析上来看,这份试题也属于同类试题中比较难的了。
Question 1:Can you use a batch SQL or store procedure to calculating the Number of Days in a Month
Answer 1:找出当月的天数
select datepart(dd,dateadd(dd,-1,dateadd(mm,1,cast(cast(year(getdate()) as varchar)+'-'+cast(month(getdate()) as varchar)+'-01' as datetime))))
阅读全文
posted @ 2007-03-10 00:03 hai 阅读(1420) 评论(1) 推荐(0)
浙公网安备 33010602011771号