Saturday, 26 November 2016

mysql - Unknown Column In Where Clause

I have a simple query:




SELECT u_name AS user_name FROM users WHERE user_name = "john";


I get Unknown Column 'user_name' in where clause. Can I not refer to 'user_name' in other parts of the statement even after select 'u_name as user_name'?

No comments:

Post a Comment

c++ - Does curly brackets matter for empty constructor?

Those brackets declare an empty, inline constructor. In that case, with them, the constructor does exist, it merely does nothing more than t...