Home | Products | Consulting | Forums | Support | Order | 1-800-752-0455
  Main
Index
Search
Posts
Who's
Online
Log
In

Home: Products: CMS Builder:
Reorder records

 

 


soj
User

Mar 25, 2008, 6:33 PM

Post #1 of 3 (181 views)
Shortcut
Reorder records Can't Post

Hi all, I'd like to reorder records in a staff list. Can anyone tell me how to do this via the system? Ascending vs Descending would be enough. TIA!

soj


Dave
Staff / Moderator


Mar 25, 2008, 8:17 PM

Post #2 of 3 (176 views)
Shortcut
Re: [soj] Reorder records [In reply to] Can't Post

Hi soj,

You can specify the sort order in the "Order By" field in the section editor or in the list viewer.

So, say you had a stafflist with a field called fullname, you could sort by the name (in ascending order) with this option:

$options['orderBy'] = "fullname";

Because this is just a regular MySQL "Order By" clause, you can use standard MySQL. So to sort in descending order you just add "DESC" after the fieldname like this:

$options['orderBy'] = "fullname DESC";

Would that work for you? Let me know if it will or if there was something else you were trying to do.

Dave Edis - Senior Developer
interactivetools.com


soj
User

Mar 25, 2008, 8:34 PM

Post #3 of 3 (173 views)
Shortcut
Re: [Dave] Reorder records [In reply to] Can't Post

Wow, I missed that option in the editor.

I'd like to order by 'record number' ascending, but it's not taking.

soj

Update - I found what I was doing wrong - I confused field name with field label. Thanks!


(This post was edited by soj on Mar 26, 2008, 7:11 AM)

 
 
 


Search for (options)
Products
CMS Builder
Article Manager
Realty Manager
Listings Manager
Order Now
Services
Priority Consulting
Support
Online Documentation
Support Forums
Support Homepage
Company Info
12 reasons to choose us!
Meet the team
Monthly newsletter
Contact Us
Toll Free: 1-800-752-0455
Phone: (604) 689-3347
Sales | Support
Conditions of Use | Privacy Policy | Copyright © interactivetools.com 2008
#201 - 2730 Commercial Drive, Vancouver BC Canada V5N 5P4