How does one reduce the number of stored revision (e.g. 5 max) for post types that support revisions?
add to your wp-config.php file the following line:
// set max post revisions define('WP_POST_REVISIONS', 5);
Just use the plugin. Simpler than screwing around with it, and provides more control.
@Piet's answer is the best, but some sql code to remove all old revisions older than 28 days:
DELETE a,b,c FROM wp_posts a LEFT JOIN wp_term_relationships b ON (a.ID=b.object_id) LEFT JOIN wp_postmeta c ON (a.ID=c.post_id) WHERE a.post_type='revision' AND a.post_date < DATE_ADD(NOW(), INTERVAL -28 DAY);
SQL and PHP code (for diffrent WP_PREFIX than "wp_") iworks_revisions.zip
I'm not sure of an automatic way but there is always running the MySQL Query
DELETE FROM wp_posts WHERE post_type = "revision" (source) I haven't done it but I'm sure it works. I'd look for a plugin by now there has to be something.