2006-07-23 21:08:06 +00:00
|
|
|
<?php
|
|
|
|
// find all users, sort by name descending
|
|
|
|
|
2006-08-21 22:51:27 +00:00
|
|
|
$coll = $conn->query("FROM User ORDER BY User.name DESC");
|
2006-07-23 21:08:06 +00:00
|
|
|
|
|
|
|
// find all users sort by name ascending
|
|
|
|
|
2006-08-21 22:51:27 +00:00
|
|
|
$coll = $conn->query("FROM User ORDER BY User.name ASC");
|
2006-07-23 21:08:06 +00:00
|
|
|
|
|
|
|
// or
|
|
|
|
|
2006-08-21 22:51:27 +00:00
|
|
|
$coll = $conn->query("FROM User ORDER BY User.name");
|
2006-07-23 21:08:06 +00:00
|
|
|
|
|
|
|
// find all users and their emails, sort by email address
|
|
|
|
|
2006-08-21 22:51:27 +00:00
|
|
|
$coll = $conn->query("FROM User, User.Email ORDER BY User.Email.address");
|
2006-07-23 21:08:06 +00:00
|
|
|
|
|
|
|
// find all users and their emails, sort by user name and email address
|
|
|
|
|
2006-08-21 22:51:27 +00:00
|
|
|
$coll = $conn->query("FROM User, User.Email ORDER BY User.name, User.Email.address");
|
2006-07-23 21:08:06 +00:00
|
|
|
?>
|