Hi
I am trying to select two rows from a single table.
One of the rows will be selected via a GET variable the other from a variable within the php code.
Currently I can select a single row using -
$username = $_GET['name'];
$query = mysql_query("SELECT * FROM users WHERE name = '$username'") or die(mysql_error());
The row above could be any of 20 users listed on a dropdown menu.
The second row is a Definite, this row will go along with the above everytime the form is submitted.
I thought I could simply create another variable within the script and use AND, however this doen't appear to be working
$username = $_GET['name'];
$adminuser = 'Administrator';
$query = mysql_query("SELECT * FROM users WHERE name = '$username' AND name = '$adminuser'") or die(mysql_error());
Best regards Maxwel