two-digit year in date field of access table: how to query

J

JJ_377

Access table stores "date" in field this way:
06/05 where 06 is the month and 05 is the year.

Oldest records have values in the date field such as:
05/98, 05/82

How to query this table to get records for years between
2005 and 2003?

Is there anyway to convert the two-digit years to four (easily) before
querying? I know how to extract the year portion by using the right
function.

Ideas?

Many thanks.
 
R

Rick Brandt

Access table stores "date" in field this way:
06/05 where 06 is the month and 05 is the year.

Oldest records have values in the date field such as:
05/98, 05/82

How to query this table to get records for years between
2005 and 2003?

Is there anyway to convert the two-digit years to four (easily) before
querying? I know how to extract the year portion by using the right
function.

Are you using a Text field or an actual Date/Time field? If the latter then
what you see is merely a display format and has nothing to do with how the
dates are stored or how you would query them. Date/times are always stored
exactly the same regardless of any format you might choose.
 
J

JJ_377

I agree with you both; good ideas!

I'm leaning towards splitting the current field (which I'm pretty sure
would be text...) into a month field and a year field: then I avoid
coding around the problem. I would leave the original field alone so I
don't break existing queries, code and eceteras.

Also BTW: what is a "read data field"?

Thank you very much Joe and Rick.
 

Ask a Question

Want to reply to this thread or ask your own question?

You'll need to choose a username for the site, which only take a couple of moments. After that, you can post your question and our members will help you out.

Ask a Question

Top