yippie_ky_yay
Registered User.
- Local time
- Today, 07:15
- Joined
- Jul 30, 2002
- Messages
- 338
Hello,
I've created a union query - the first query has a date field that the other does not (it's supposed to be blank). So, in the one that is supposed to have a blank for that field, I wrote: "Null AS myDate". Both queries work fine on their own, in the union query however, the entire column shows up as blank!
I suspect that the reason is that I have not included anything to let SQL know that myDate is to be a date field (???), so I tested by creating my field like this instead: "#1/1/1900# AS myDate"
This works, but I would rather know how to do this properly!
Thanks in advance!
-Sean
I've created a union query - the first query has a date field that the other does not (it's supposed to be blank). So, in the one that is supposed to have a blank for that field, I wrote: "Null AS myDate". Both queries work fine on their own, in the union query however, the entire column shows up as blank!
I suspect that the reason is that I have not included anything to let SQL know that myDate is to be a date field (???), so I tested by creating my field like this instead: "#1/1/1900# AS myDate"
This works, but I would rather know how to do this properly!
Thanks in advance!
-Sean