Anytime! Glad to help! I've been helped many, many times, as well! Have a great day!
Rick > -----Original Message----- > From: John Barrett [mailto:[email protected]] > Sent: Monday, January 12, 2009 2:04 AM > To: cf-newbie > Subject: Re: cfquery & alphabetical order > > Hi Rick, > > > Thanks for pointing this out to me, after coming up with the cfquery I > noticed that it was not needed > when I had: > order by short_desc asc. > I did not know about all this would by default alphabetizes the query, thank > you for pointing this out > to me. > Basically it is a Link management system that I made > > It is so nice to start to be really learning ColdFusion and writing code, > been having so much fun with > this project at school, and everybody's help on this list has been so helpful! > > Thanks again for your help, > John > > > > > > > ________________________________ > From: Rick Faircloth <[email protected]> > To: cf-newbie <[email protected]> > Sent: Sunday, January 11, 2009 7:32:22 PM > Subject: RE: cfquery & alphabetical order > > Yes, and the "order by" in the SQL is the best method, I believe, > for ordering your output. It's the method I use all the time. > > By default "order by" alphabetizes in ascending order. In case you > weren't aware of another option, "order by short_desc desc" will > order your output in reverse order. > > Rick > > > -----Original Message----- > > From: John Barrett [mailto:[email protected]] > > Sent: Sunday, January 11, 2009 11:46 PM > > To: cf-newbie > > Subject: Re: cfquery & alphabetical order > > > > Hi Paul, > > Thanks so much,and I am happy that I am finally starting to get CF`-` > > > > John > > > > On Jan 11, 2009, at 6:01 PM, Paul Kukiel wrote: > > > > > Looks fine to me this could be shortend > > > > > > <cfoutput query="getKeywords" group="short_desc"> > > > #short_desc#<br /><br /> > > > </cfoutput> > > > > > > Paul. > > > > > > -----Original Message----- > > > From: John Barrett [mailto:[email protected]] > > > Sent: Sunday, 11 January 2009 10:27 PM > > > To: cf-newbie > > > Subject: cfquery & alphabetical order > > > > > > Hi, > > > I am wondering what the best way to have a cfquery to become in a > > > alphabetical order. What are the best practice, I don't think that > > > I am > > > using it here. In the SLECT LEFT(column name,number of caharacters) > > > is there > > > a limit on the number of characters? I would prefer to just get the > > > entire > > > cell. > > > > > > Maybe I should not complain, as the code works fine, and does what > > > I what, > > > displays the listing in alphabetical order, but I am trying to > > > learn the > > > best way to do this. > > > > > > Thanks so much, > > > John > > > here is my code: > > > > > > <cfquery name="getKeywords" datasource="my_datsource"> > > > SELECT LEFT(short_desc,100) AS short_desc > > > FROM senior_links > > > ORDER BY short_desc > > > </cfquery> > > > > > > <cfoutput query="getKeywords" group="short_desc"> > > > <cfoutput>#short_desc#<br> > > > </cfoutput><br /> > > > </cfoutput> > > > > > > > > > > > > > > > > > > > > > > > > > > > > > ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~| Adobe® ColdFusion® 8 software 8 is the most important and dramatic release to date Get the Free Trial http://ad.doubleclick.net/clk;207172674;29440083;f Archive: http://www.houseoffusion.com/groups/cf-newbie/message.cfm/messageid:4286 Subscription: http://www.houseoffusion.com/groups/cf-newbie/subscribe.cfm Unsubscribe: http://www.houseoffusion.com/cf_lists/unsubscribe.cfm?user=11502.10531.15
