Refer to renamed columns in WHERE clause SELECT name, gdp/population as capita 
FROM world w1 
WHERE continent = 'Europe'      
AND capita &gt; 
(
    SELECT gdp/population 
    FROM world 
    WHERE name = 'United Kingdom'
);


How come I can't refer to capita in the WHERE clause? It returns this error:

Unknown column 'capita' in 'where clause'


I can however, run the query if I replace capita with gdp/population.

I don't want to do gdp/population &gt; .... How can I do capita &gt; ...? Or is this not possible?
You should use a View in your database

USE mydb;
CREATE VIEW name_capita AS
SELECT name, gdp/population as capita,continent FROM world;


Then, apply the WHERE clause to the View

USE mydb;
SELECT * FROM name_capita
WHERE continent = 'Europe' AND
capita &gt; (SELECT gdp/population FROM world WHERE name = 'United Kingdom');


or even re-using the view:

SELECT * FROM name_capita
WHERE continent = 'Europe' AND
capita &gt; (SELECT capita FROM name_capita WHERE name = 'United Kingdom');


GIVE IT A TRY !!!