Something like this should work: select count(state), state from orders group by state having (count(state) > 400)
Mahmut from Turkiye ----- Original Message ----- From: "Brook Davies" <[EMAIL PROTECTED]> To: "CF-Talk" <[EMAIL PROTECTED]> Sent: Thursday, June 26, 2003 12:10 AM Subject: SQL Question: Selecting records where there are multiple occurrences > Is there an easy way to select records that occur X number of times. So I > could select the records that have "San Fran" in the City fields only if > there are at least X number of records matching this criteria. > > Brook > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/cf_lists/index.cfm?method=subscribe&forumid=4 FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Host with the leader in ColdFusion hosting. Voted #1 ColdFusion host by CF Developers. Offering shared and dedicated hosting options. www.cfxhosting.com/default.cfm?redirect=10481 Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=89.70.4

