I need to have 3 columns in a table called prize
Fields are: Event_id, Place, Place
I need to find the square root of the prize money divided by 2, round to a whole number and then display this in a column called New_Money with the 3 other columns (Event_id, Place, Money) without actually storing the New_Money data in a table. Oh, I also have to use the power function.
I started testing with:
SELECT ROUND(money*money/2) AS New_Money
FROM prize;
This gave me a column called New_Money with the correct data, but no other columns.
I couldn’t work out how to get the other columns to display in the same string, AND this isn’t using the Pow() function anyway.
I tested:
SELECT pow(money,money) AS New_Money
FROM prize;
But gave an error and is still “fetching” 5 minutes later….
Any ideas?
You are using POW in a wrong way. Try this