Unknown Column In Where Clause
SQL is evaluated backwards, from right to left. So the where clause is parsed and evaluate prior to the select clause. Because of this the aliasing of u_name to user_name has not yet occurred.
What about:
SELECT u_name AS user_name FROM users HAVING user_name = "john";