Skip to content
  • Categories
  • Recent
  • Tags
  • Popular
  • World
  • Users
  • Groups
Skins
  • Light
  • Cerulean
  • Cosmo
  • Flatly
  • Journal
  • Litera
  • Lumen
  • Lux
  • Materia
  • Minty
  • Morph
  • Pulse
  • Sandstone
  • Simplex
  • Sketchy
  • Spacelab
  • United
  • Yeti
  • Zephyr
  • Dark
  • Cyborg
  • Darkly
  • Quartz
  • Slate
  • Solar
  • Superhero
  • Vapor

  • Default (No Skin)
  • No Skin
Collapse
Code Project
  1. Home
  2. Database & SysAdmin
  3. MySQL
  4. Problem with query

Problem with query

Scheduled Pinned Locked Moved MySQL
databasehelp
5 Posts 5 Posters 21 Views 1 Watching
  • Oldest to Newest
  • Newest to Oldest
  • Most Votes
Reply
  • Reply as topic
Log in to reply
This topic has been deleted. Only users with topic management privileges can see it.
  • S Offline
    S Offline
    sarang_k
    wrote on last edited by
    #1

    Hi all, I want to write a query in such a way to find the list of records which are between two dates i.e., consider the two dates are StartDate and EndDate. Thanks in advance.

    L A D N 4 Replies Last reply
    0
    • S sarang_k

      Hi all, I want to write a query in such a way to find the list of records which are between two dates i.e., consider the two dates are StartDate and EndDate. Thanks in advance.

      L Offline
      L Offline
      Luc Pattyn
      wrote on last edited by
      #2

      that is elementary. read a book on databases, using the relevant Query Language. And don't post the same question in more than one forum. :|

      Luc Pattyn [Forum Guidelines] [Why QA sucks] [My Articles]


      I only read code that is properly formatted, adding PRE tags is the easiest way to obtain that.
      [The QA section does it automatically now, I hope we soon get it on regular forums as well]


      1 Reply Last reply
      0
      • S sarang_k

        Hi all, I want to write a query in such a way to find the list of records which are between two dates i.e., consider the two dates are StartDate and EndDate. Thanks in advance.

        A Offline
        A Offline
        April Fans
        wrote on last edited by
        #3

        I think you should consider the StartDate only. SELECT listname form TABLE WHERE StartDate>='####-##-##' and StartDate<='####-##-##'

        April Comm100 - Leading Live Chat Software Provider

        1 Reply Last reply
        0
        • S sarang_k

          Hi all, I want to write a query in such a way to find the list of records which are between two dates i.e., consider the two dates are StartDate and EndDate. Thanks in advance.

          D Offline
          D Offline
          DX Roster
          wrote on last edited by
          #4

          try below query SELECT * FROM tablename WHERE startdate AND enddate IF YOU GET YOUR ANSWER THAN PLEASE RATING ME If You Get your answer then please Rating me... Thanks.. "Are You Ready" DX-ARMY

          1 Reply Last reply
          0
          • S sarang_k

            Hi all, I want to write a query in such a way to find the list of records which are between two dates i.e., consider the two dates are StartDate and EndDate. Thanks in advance.

            N Offline
            N Offline
            nidhip
            wrote on last edited by
            #5

            hi u can try this query select * from tablename whare Datefieldname between StartDate and EndDate reply if ur problem resolved thanks

            1 Reply Last reply
            0
            Reply
            • Reply as topic
            Log in to reply
            • Oldest to Newest
            • Newest to Oldest
            • Most Votes


            • Login

            • Don't have an account? Register

            • Login or register to search.
            • First post
              Last post
            0
            • Categories
            • Recent
            • Tags
            • Popular
            • World
            • Users
            • Groups