udpate tablename set column = 0 where id > 100 and id < 200 and mod(id, 2) = 0
The mod() may or may not work depending on the database ... but should be easy to replace to make it work ... Dan -----Original Message----- From: Tony Carcieri [mailto:[EMAIL PROTECTED]] Sent: Wednesday, October 09, 2002 1:54 PM To: CF-Talk Subject: OT: SQL Question Hi all, Here's what I want to do: UPDATE tablename SET column = 0 WHERE ID = ??????? I want to specify a range of numbers (like 100-200) and increment it by 2. So, 100, 102,104etc would only be updated and the rest wouldn't. Any ideas? Thanks, T ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Archives: http://www.houseoffusion.com/cf_lists/index.cfm?forumid=4 Subscription: http://www.houseoffusion.com/index.cfm?sidebar=lists&body=lists/cf_talk FAQ: http://www.thenetprofits.co.uk/coldfusion/faq Structure your ColdFusion code with Fusebox. Get the official book at http://www.fusionauthority.com/bkinfo.cfm

