How to use max and min values of custom fields

How to use max and min values of custom fields