postgresql7.2 SELECT r.title as resource_title, r.description as resource_description, r.revision_id as resource_revision_id, r.item_id as resource_item_id, c.short_name as category_name FROM rl_resources_revisionsx r, rl_resources rl, cr_items i, rl_resource_category_map m, rl_resource_category c WHERE r.resource_revision_id = i.live_revision and m.resource_item_id = r.item_id and m.category_id = c.category_id and r.item_id = rl.resource_item_id and rl.approved_p = 'f' ORDER BY r.item_id, r.title, c.short_name