MySQL Forums :: Perl :: Query for unkown column name
Query for unkown column name
Posted by: Rene Jaspers
Date: June 19, 2012 06:12AM
Oke here it goes,
i have 2 tables (exchangerate and player)
player has a column called currency
and exchangerate has columns named after those currencies
So what i would like to do is this
player.currency, (like eur of usd)
exchangerate.[player.currency] as exchangerate
inner join exchangerate on ( exchangerate.date = DATE(NOW()) )
player.id = 1;
Giving me the following row
[name] [currency] [exchangerate]
John 'usd' 1.2345
Any help is nice!
Sorry, you can't reply to this topic. It has been closed.
Content reproduced on this site is the property of the respective copyright holders. It is not reviewed in advance by Oracle and does not necessarily represent the opinion of Oracle or any other party.