A friendly place for programming greenhorns!
Big Moose Saloon
Register / Login
Win a copy of
EJB 3 in Action
this week in the
EJB and other Java EE Technologies
MS Access and Date
Joined: Feb 27, 2003
Nov 12, 2003 10:57:00
I have a MS Access table which contains a Date tag on each record.
I want to retrieve records based on:
Today - 1 month
Today - 2 weeks
Can anyone tell me the syntax?
Joined: Sep 28, 2002
Nov 12, 2003 19:13:00
I am assuming you want SYSDATE (minus) a number of days. If so, have you tried the following:
SYSDATE - 6?
I hope this helps.
We make a living by what we get, we make a life by what we give!
Joined: Oct 13, 2003
Nov 17, 2003 01:50:00
SELECT * FROM MyTable WHERE MyDate BETWEEN Now() AND DateAdd("d", -6, Now())
SCJP2 , MCP( 70-229 ) , Preparing For SCWDC
Did you see how Paul
cut 87% off of his electric heat bill with 82 watts of micro heaters
subject: MS Access and Date
Convert Datetype from Access database to Java 'DATETIME'
About convert datetype 'DATETIME' From SQL (access 2000)into JAVA
How can convert DATETIME type to JAVA date type?
All times are in JavaRanch time: GMT-6 in summer, GMT-7 in winter
| Powered by
Copyright © 1998-2014