获取MySQL-Error“未知列”但该列存在

the searchfunction did'nt help me.. My MySQL-Query looks like this:

SELECT * FROM user WHERE username = flo;

and I get this error:

Unknown column 'flo' in 'where clause'

But why? My database does have the table "user", containing multible columns, one column is named "username".

I also have 2 Test-Users, one of their usernames is "flo" so what is wrong?

Thanks for your help!

The reason why you are getting that error message Florian, is because the word flo needs to be wrapped inside quotes.

SELECT * FROM user WHERE username = 'flo';

In SQL, doing WHERE column = column is valid syntax, but in your case, you are wanting to see if column = (contains) string.