Sounds like a great idea, too! Thanks! Rick
> -----Original Message----- > From: AJ Mercer [mailto:[EMAIL PROTECTED] > Sent: Wednesday, March 12, 2008 11:15 PM > To: CF-Talk > Subject: Re: Best way to order appearance of database content... > > how about, with sql > update all display-order greater than new value (in your example 15), > incrementing by 10 > then update display order = 20 where currently = 15 > > On Thu, Mar 13, 2008 at 12:05 PM, Rick Faircloth <[EMAIL PROTECTED]> > wrote: > > > I know that doesn't sound like it's CF-related, but the solution > > probably will be in CF, I'll bet. > > > > Anyway.I want to be able to determine the appearance order of > > Real Estate agents on a page, other than by last name, etc. > > > > I want a user to be able to specify the appearance, say, by number. > > I could have an "display-order" column and use a number. > > > > I would also want to have the numbers round up to the nearest 10 > > whenever a new agent is entered or when an agent's display order is > > updated. > > > > Say, I've got two agents in the db. First has display-order 10, second > > has > > display-order 20. A third agent is added who is to be displayed second, > > so > > is given the display-order number 15 in the form. When the form is > > submitted, > > the first agent retains number 10, the new second agent's number is > > rounded up from 15 > > to 20, and the agent whose number was 20 now has the number 30. That way > > there > > are always values between the agents' display-order numbers to add new > > agents. > > > > Make any sense? > > > > Would this be the best way to do this? Other ways? > > > > Thanks, > > > > Rick > > > > > > > > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;160198600;22374440;w Archive: http://www.houseoffusion.com/groups/CF-Talk/message.cfm/messageid:301141 Subscription: http://www.houseoffusion.com/groups/CF-Talk/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.4

