Easy way to load custom fields per post?

We are trying to integrate Custompress with WP dtree widget. We would like the tree to be based on certain custompress field values. Is there an easy way to do this? We figured we can replace the archive-by-year sorting option if we can load the field values properly.

For example, the tree does the following query to sort the posts by year:

$query = "SELECT YEAR({$wpdb->posts}.post_date) AS 'year', MONTH({$wpdb->posts}.post_date) AS 'month' {$count}
WHERE {$wpdb->posts}.post_type = '{$posttype}' AND {$wpdb->posts}.post_status = 'publish'
GROUP BY year, month
ORDER BY {$wpdb->posts}.post_date DESC";
$arcresults = $wpdb->get_results($query);

So is there an equivalent to "$wpdb->posts}.post_type" but that will load the field values that we specify?