在sqlserver 2005中插入日期 [英] inserting date in sqlserver 2005
本文介绍了在sqlserver 2005中插入日期的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!
问题描述
hai,有人可以告诉我如何使用日期时间选择器在sqlserver的日期时间字段中分别插入日期和时间.
hai,can anybody please tell me how to insert date and time separately in datetime fields in sqlserver using datetime picker.
推荐答案
CSharp时间帮助
检查这些 [
CSharp Time Help
Check these[^]
AFAIK您不能仅插入date
或仅插入time
在datetime
字段中.
您只能基于字符串格式 [
AFAIK You cannot insert onlydate
or onlytime
in adatetime
field.
You can display only time or date based on string formats[^] in front end.
CONVERT(TIME(0),GETDATE()) AS HourMinuteSecond,
CONVERT(DATE,GETDATE(),101) AS DateOnly
这篇关于在sqlserver 2005中插入日期的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!
查看全文