Results 1 to 8 of 8

Thread: Datetime Query

  1. #1
    Join Date
    Sep 2007
    Posts
    5

    Unanswered: Datetime Query

    How to display records between datetime field??

  2. #2
    Join Date
    Nov 2002
    Location
    Jersey
    Posts
    10,322
    WHERE dateCol BETWEEN @date1 AND @date2

    ?????
    Brett
    8-)

    It's a Great Day for America everybody!

    dbforums Yak CorralRadio 'Rita
    dbForums Member List
    I'm Good Once as I ever was

    The physical order of data in a database has no meaning.

  3. #3
    Join Date
    Sep 2007
    Posts
    5

    Datetime Query

    how do i display records between two fields Callstartdt and endcalldt bot the fields are datetime fields...

    What would be syntax for the query??

    Please help..

  4. #4
    Join Date
    Nov 2002
    Location
    Jersey
    Posts
    10,322
    You really have to give us more information

    Like ddl, sample data and expected results

    Read the hint sticky at the top of the forum to see how to post a question here
    Brett
    8-)

    It's a Great Day for America everybody!

    dbforums Yak CorralRadio 'Rita
    dbForums Member List
    I'm Good Once as I ever was

    The physical order of data in a database has no meaning.

  5. #5
    Join Date
    Sep 2007
    Posts
    5

    Datetime query

    Do i need to post the design of the table??

    How do i copy a design of the table...

    I want to display all the records between two dates.

  6. #6
    Join Date
    Nov 2002
    Location
    Jersey
    Posts
    10,322
    go to enterprise mangler and right click on the table

    Choose all tasks then generate sql server script

    Did you read the hint link at the top of the page?

    it's all explained up there, but in any case

    When you say betyween 2 dates?

    Which 2 dates?

    Or is it a number of days betwen 2 dates

    The question is not very clear, and that's why code examples would help us immensly
    Brett
    8-)

    It's a Great Day for America everybody!

    dbforums Yak CorralRadio 'Rita
    dbForums Member List
    I'm Good Once as I ever was

    The physical order of data in a database has no meaning.

  7. #7
    Join Date
    Jan 2004
    Location
    In a large office with bad lighting
    Posts
    1,040
    Quote Originally Posted by ashutoshmahudkar
    How to display records between datetime field??
    Code:
     
              ***********
    datetime  * records * field
              ***********

    -- This is all just a Figment of my Imagination --

  8. #8
    Join Date
    Jan 2007
    Location
    UK
    Posts
    11,434
    Provided Answers: 10
    Lmao!
    George
    Home | Blog

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •