Last updated June 9, 2009. Created on March 17, 2006.
Edited by bekasu, hunmonk, merlinofchaos. Log in to edit this page.

The sort criteria on a View controls the order in which views results are presented. In general, sort criteria are specified by a direction, and the order is important.

For example, if a view is sorted by taxonomy term ascending, and then title descending, then the entire list of posts will be sorted by what taxonomy term they belong to. (Note: vocabularies where multiple terms are allowed for this setting will produce apparently nonsensical results!) Then, all posts which belong to the same term will be sub-sorted by title in reverse alphabetical order.


Watch out for double sorting. Using Sort Criteria and using Default Sorts in the Fields can give odd results.

This simply says what field to sort by.
Either Ascending order, which means lowest value to highest value (Example: 1, 2, 3, 4 or a, b, c) or Descending, which means highest value to lowest value (4, 3, 2, 1 or c, b, a).
An option that is specific to a given sort criteria. At this time no sort criteria have an option, but may in the future.

What follows is a list of sorting criteria supported by Views by default. More may be available, supplied by modules with Views support.

Node: Created Time
Sort by the submission date of the node.
Node: Last Updated Time
Sort by the last update date of the node.
Node: Sticky
Sort by whether or not the node is sticky. Choose descending to put sticky nodes at the top.
Node: Title
Sort by the node title, alphabetically
By choosing random, nodes will be ordered completely randomly. This is a good way to choose X random nodes from a group of nodes.
Node: Author Name
This allows you to sort alphabetically by author.
Comment: Last Comment Date
This will allow you to sort by the date of the most recent comment on a node.
Taxonomy: Term Name
This will sort nodes by taxonomy weight and name, as defined in the category administration.

Looking for support? Visit the forums, or join #drupal-support in IRC.


dman’s picture

If you want to sort by term Weight (as managed in the taxonomy term lists) not alphabetical, the short instructions at Sort by term weight was helpful.

BigEd’s picture

If you want to order by a specific list or value try expanding on this with some of the contributed modules.