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 |
|
PatDeV
Posting Yak Master
197 Posts |
Posted - 2006-02-09 : 14:06:38
|
| Hi all,sorry for silly question but how can i count days between two rangesfor example btween getdate() and 01/16/2005 and return days btween this.Thanks |
|
|
jsmith8858
Dr. Cross Join
7423 Posts |
Posted - 2006-02-09 : 14:07:34
|
| Look up DateDiff() in books on-line.DateDiff(dd,Date1,Date2) returns the difference in days between date1 and date2. |
 |
|
|
tkizer
Almighty SQL Goddess
38200 Posts |
Posted - 2006-02-09 : 14:09:07
|
You can use DATEDIFF. Check out this date function in SQL Server Books Online for more information. by Jeff.Tara Kizeraka tdugganTara Kizeraka tduggan |
 |
|
|
|
|
|