Improve company productivity with a Business Account.Sign Up

x
  • Status: Solved
  • Priority: Medium
  • Security: Public
  • Views: 467
  • Last Modified:

How do I search DateTime Data in MS SQL 2005?

I am trying to create search page in ASP classic.

How do I create a query that will select similar date?
For Example, when I use this query " Select * from Board where RegisterDate ='2007-11-28' " it gave me a blank result because I didn't input the time.
So I used "Like" query, and it still gives me a blank result.
Select * from Board where RegisterDate Like '%2007-11-28%' "

How do I select the date without inputing time?

Thank you
0
erin027
Asked:
erin027
1 Solution
 
Aneesh RetnakaranDatabase AdministratorCommented:
Select * from Board where RegisterDate >='2007-11-28'  and RegisterDate <'2007-11-29'   ---- original date +1
0
Question has a verified solution.

Are you are experiencing a similar issue? Get a personalized answer when you ask a related question.

Have a better answer? Share it in a comment.

Join & Write a Comment

Featured Post

Keep up with what's happening at Experts Exchange!

Sign up to receive Decoded, a new monthly digest with product updates, feature release info, continuing education opportunities, and more.

Tackle projects and never again get stuck behind a technical roadblock.
Join Now