MAX() operator with auto number field
From: kasab (kasab_at_discussions.microsoft.com)
Date: 03/27/05
- Next message: kasab: "RE: MAX() operator with auto number field"
- Previous message: DJ matrix: "Update Field On Differant Form"
- Next in thread: kasab: "RE: MAX() operator with auto number field"
- Reply: kasab: "RE: MAX() operator with auto number field"
- Messages sorted by: [ date ] [ thread ]
Date: Sat, 26 Mar 2005 16:35:02 -0800
The following query returns the wrong answer:
SELECT Max(job.job_id) AS MaxOfjob_id FROM job;
In this case, job_id is an auto number field of the job table, and its
primary key. I built the query interactively using the Query grid.
The problem is that there are 10 records in the job table (no deletions), so
the maximum job_id should be 10. It is consistently 9.
Why?
How can I get the correct answer (interactively, or using VBA)?
Thanks for your help
- Next message: kasab: "RE: MAX() operator with auto number field"
- Previous message: DJ matrix: "Update Field On Differant Form"
- Next in thread: kasab: "RE: MAX() operator with auto number field"
- Reply: kasab: "RE: MAX() operator with auto number field"
- Messages sorted by: [ date ] [ thread ]
Relevant Pages
|
|