This is my query...
List<Opportunity> opportunities = Database.query('SELECT OwnerId, Amount, Probability, ExpectedRevenue ' + mycustomatt + ' FROM OPPORTUNITY ' + ' where isClosed = false');
mycustomatt is a String that is determine at runtime.
If I iterate over the opportunities, how can I get the value for mycustomatt?
for (Opportunity opportunity: opportunities) {
// can get amount by doing
System.debug('amount=' + opportunity.Amount);
// ??? But how do I get the values for my customatt
// ???
Thanks