average number of days

  • select statement for average number days between two dates...

  • DATEDIFF ( datepart , startdate , enddate )

    for days use datepart as dd

    Check out:

    http://msdn.microsoft.com/en-us/library/ms189794.aspx

    Tanx 😀

  • purushotham.k9 (5/27/2009)


    select statement for average number days between two dates...

    Sorry, but what is your question? Are you asking what the average number of days is between say 1 January 2009 and 31 January 2009? Guess there ain't such a thing. If you meant to ask what's the average number of days between some arbitrary date like 2 June in some year and a date somewhere in the future like 2 June 2309 and calculating the average days per year in between, then that's a different issue, but at least it would have made a question.

    --------------------------------------------------------------------------
    A little knowledge is a dangerous thing (Alexander Pope)
    In order for us to help you as efficiently as possible, please read this before posting (courtesy of Jeff Moden)[/url]

Viewing 3 posts - 1 through 2 (of 2 total)

You must be logged in to reply to this topic. Login to reply