Never mind. Figured it out..
PAYMENT_TYPES.rassoc("MC")[0] would give you "MasterCard"
Thanks
That's pretty inefficient. You could use a hash:
PAYMENT_TYPES = { 'MC'=>'MasterCard', 'VISA'=>'Visa', 'AMEX'=>'American Express']
and then: PAYMENT_TYPES['MC']
You should strongly consider storing the display names in the database as well. Your current setup distributes the business data across two different layers (database and domain model), which is generally not a good idea.
Max