I've trouble in quering the data from MySQL when using the query function within PHP.
I 've created a Database "test", Table "employee", i 've two columns "username" and "password", I've data "admin" and "admin" on both username and the password columns. $u and $p variables has "admin".
Expand|Select|Wrap|Line Numbers
- <?php
- $query = "SELECT username and password FROM employee WHERE username = $u AND password = $p";
- $result = mysql_query ($query);
- ?>
Unknown column admin in where clause
is the query statement correct ?
Any help appreciated !