Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
pradeep_iete
Yak Posting Veteran
84 Posts |
Posted - 2008-07-14 : 05:18:21
|
| DECLARE @date nvarchar(20); SET @date=CONVERT(datetime,getdate(),103)I want only date part (time string must be all zero)INSERT <table> (date) --'date' datatype id datetime VALUES ( @date)--This is showing error overflow |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2008-07-14 : 05:20:15
|
[code]INSERT <table>(date) select dateadd(day, datediff(day, 0, getdate()), 0)[/code] KH[spoiler]Time is always against us[/spoiler] |
 |
|
|
|
|
|