select date problem

Results 1 to 2 of 2

Thread: select date problem

  1. #1
    Join Date
    Dec 1969

    Default select date problem

    I&#039;ve got a variable on the page = date() and am trying to select all records from the database where the date = date() but the field in the database is in datetime format - does it matter? <BR><BR>Each time I try SELECT * FROM TABLE WHERE date = todaydatevariable and I get either BOF or EOF is true.. I tried using LIKE with no success - any input? (or an faq to point me to?) <BR><BR>Thanks!<BR>

  2. #2
    Join Date
    Dec 1969
    Los Angeles, CA

    Default RE: select date problem

    try this for SQL server<BR><BR>SELECT * FROM TABLE WHERE convert(varchar(10), date , 101)<BR>= &#039;todaydatevariable&#039;<BR><BR><BR>dont forget the &#039;..&#039;<BR><BR>

Posting Permissions

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