Help - with Year to Data query

  • Thread starter Thread starter Karen Middleton
  • Start date Start date
K

Karen Middleton

John

Sorry for the missing info.

Calmonth is a number(integer).

The format in which the data is stored is 2004012 , 2004009,etc

Thanks
Karen
 
John

Sorry for the missing info.

Calmonth is a number(integer).

The format in which the data is stored is 2004012 , 2004009,etc

Thanks
Karen

I'm still wondering... WHY. Access provides a very flexible Date/Time
datatype field. True, a Date/Time must be an exact date, not an entire
month; but you could store data for this December in a field with a
date of 12/1/2004, and use a Format property like "yyyy\0mm" to
regenerate your current date format if you wish. (Why the middle zero
is another question...)

My suggestions should be adaptable to Calmonth being an integer. Just
use it in the second (month) argument of DateSerial. You'll still need
to somehow get the year from the user, or write some code to read the
user's mind and determine whether they want this year-to-date or last
year total, should they run the query a week from now.

John W. Vinson[MVP]
 

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

Similar Threads


Back
Top