Since you want to treat 767.24 as just 767, the values have to be converted to Integers (?) first, or rounded down to the whole number, so I would try something like:
[tt]
Select DOS, COUNT(CINT(CODE)) AS MYCOUNT
FROM MyTable
WHERE CODE BETWEEN 767 AND 767.99999
GROUP BY DOS[/tt]
OCM,
You have been a member here for 16 years and started 65 threads. I'm not sure why your first post couldn't have been similar to Andy's first reply with some sample records and desired output?
Andy took the time to enter and format some sample records as well as suggest the expected output . This is awesome support from Andy (many other Tek-Tippers do the same).
A little extra effort on the part of Original Posters (0Ps) who ask questions would go a long way to improving understanding, shortening the resolution, and showing effort on the OP's part.
This site uses cookies to help personalise content, tailor your experience and to keep you logged in if you register.
By continuing to use this site, you are consenting to our use of cookies.