B
Bart Willems
A coworkers database is showing problems when querying the ID
(autonum, long int) field. For instance:
SELECT * FROM tbl_ref WHERE code=237
will not return *anything*, but
SELECT * FROM tbl_ref WHERE code<>237
will correctly return all rows except the ones with code 237.
In similar fashion running an inner join on the code field will return
0 records:
SELECT tbl_people.* FROM tbl_people INNER JOIN tbl_ref ON
tbl_people.role = tbl_ref.code
But, turning the inner join into a left join will make things run just
fine:
SELECT tbl_people.* FROM tbl_people LEFT JOIN tbl_ref ON
tbl_people.role = tbl_ref.code
The why and how of this bug puzzles me. I'm starting to find
workarounds so that's not the issue, I'm just curious as to what is
going on and if this is a known issue in Access 2003. Any clues
anyone? Bueller?
(autonum, long int) field. For instance:
SELECT * FROM tbl_ref WHERE code=237
will not return *anything*, but
SELECT * FROM tbl_ref WHERE code<>237
will correctly return all rows except the ones with code 237.
In similar fashion running an inner join on the code field will return
0 records:
SELECT tbl_people.* FROM tbl_people INNER JOIN tbl_ref ON
tbl_people.role = tbl_ref.code
But, turning the inner join into a left join will make things run just
fine:
SELECT tbl_people.* FROM tbl_people LEFT JOIN tbl_ref ON
tbl_people.role = tbl_ref.code
The why and how of this bug puzzles me. I'm starting to find
workarounds so that's not the issue, I'm just curious as to what is
going on and if this is a known issue in Access 2003. Any clues
anyone? Bueller?