• Post Reply Bookmark Topic Watch Topic
  • New Topic
programming forums Java Mobile Certification Databases Caching Books Engineering Micro Controllers OS Languages Paradigms IDEs Build Tools Frameworks Application Servers Open Source This Site Careers Other Pie Elite all forums
this forum made possible by our volunteer staff, including ...
Marshals:
  • Campbell Ritchie
  • Jeanne Boyarsky
  • Ron McLeod
  • Paul Clapham
  • Liutauras Vilda
Sheriffs:
  • paul wheaton
  • Rob Spoor
  • Devaka Cooray
Saloon Keepers:
  • Stephan van Hulst
  • Tim Holloway
  • Carey Brown
  • Frits Walraven
  • Tim Moores
Bartenders:
  • Mikalai Zaikin

Comparing Dates in MS Access

 
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Hai Friends
I am using MS ACCESS 2000 Database
I am using the following sqlString in AWT Frame class to fetch the date from MS ACcess Database
I heard that while comparing with >= or <= we need to include # symbol between the date.<br /> I was tried by using #. But i am not able to get the results.<br /> please see the sql query and give me the solution.<br /> Thanksinadvance<br /> Yours<br /> Rajesh<br /> if(Enddate.getText().trim().equals(""))<br /> {<br /> sqlString = "select * from data_comm_err where log_date >= '" + Startdate.getText() + "'";
}
if(Startdate.getText().trim().equals(""))
{
sqlString = "select * from data_comm_err where log_date <= '" + Enddate.getText() + "'";
}
 
Ranch Hand
Posts: 1879
MySQL Database Suse
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
The following works for me:
Non-portable MSAccess specific:

Portable --> recommended

Jamie
[This message has been edited by Jamie Robertson (edited November 12, 2001).]
 
Suji N
Ranch Hand
Posts: 35
  • Mark post as helpful
  • send pies
    Number of slices to send:
    Optional 'thank-you' note:
  • Quote
  • Report post to moderator
Thankyou Mr. Jamie
Your Code is Working Fine
Thankyou Very Much

Originally posted by Jamie Robertson:
[B]The following works for me:
Non-portable MSAccess specific:

Portable --> recommended

Jamie
[This message has been edited by Jamie Robertson (edited November 12, 2001).][/B]


reply
    Bookmark Topic Watch Topic
  • New Topic