T Tom Aug 11, 2003 #1 A query returns the numbers 22,23,24,34,35,36. I need a function that will return 22-24, 34-36 Thanks for all help! Tom
A query returns the numbers 22,23,24,34,35,36. I need a function that will return 22-24, 34-36 Thanks for all help! Tom
S Sam Aug 11, 2003 #2 I think you'll need to group based on Integer division by 10 then do your Min and Max on this grouped data. Something like.... SELECT Min([NumField]) & "-" & Max([NumField]) AS Range FROM tblYourTable GROUP BY [NumField]\10 Maybe, tblYourTable should be replaced by your existing query's name HTH Sam
I think you'll need to group based on Integer division by 10 then do your Min and Max on this grouped data. Something like.... SELECT Min([NumField]) & "-" & Max([NumField]) AS Range FROM tblYourTable GROUP BY [NumField]\10 Maybe, tblYourTable should be replaced by your existing query's name HTH Sam