Basically, three steps involved for my data.
1) I setup Posting Date with "Date/Time" under Date Type in Table A and
Table B (Format is Short Date, Input mask is 99/99/0000;0;_).
2) I did a union SQL to combine Table A and Table B files. I use " " for
date if there is no matched value. Here is my Query in SQL:
SELECT [table a].posting date
UNION " "
FROM...
WHERE...;
3) Query based on date range. Here is my Query in SQL:
SELECT [Query Step 2].[Posting Date]
FROM [Query Step 2]
WHERE ((([Query Step 2].[Posting Date]) Between #4/15/2007# And
#4/20/2007#));
After review everyone's input, I found out the problem might occured in
Step
2.
I tried to use " and # in step 3 or change " " to "01/01/9999" in Step 2,
but got the same wrong date "4/2/2007".
Should I change field properties foramt in Step 3 Query? What should I
type
in? Or do anything else?
Thanks for help!
Cynthia
Cynthia said:
I am new with access 2003. I set up date format in table. When I query
a
date range criteria between "4/15/2007" and "4/20/2007", why "4/2/2007"
show
up? How can I fix this problem?
Thanks,
Cynthia