in reply to Database design and Class::DBI

If I think I understand you right (no guarantee..it's been a long day :-) ), and if I was using a dbms that supports it, I'd plump for price_type being an enumerated set of some kind ('enum' in MySQL), thus avoiding the need for a 3rd table. The enum type can be accessed either with id_number or string.

So your prices table has a
price_type : enum('Sale Price',List Price','Cost')
Then your select simply becomes
select amount from prices where id=$id and price_type ='$price_type';
...where $price_type can either be a string or an id number (1..3)
There are various ways to enumerate the values in the 'enum' field, allowing you to check for valid types before performing the select - I suspect many of them may DBMS-dependent though.
Hope this helps.