what I am doing is grabbing all records that are not yet assigned to a particular value.
the recoed returned will have the value of the timestamp in it.
then the update script would come up... then the script would loop to the next record.
What I would like to do is have this script update only the one record. I would like for it to grab whatever value is appropriate from the found record. This way when the script loos to the next record, the value is unique to that record.
I know this is not comming out clearly.
<?
//Database user info
$username="root";
$password="";
$database="tracker";
$server="localhost";
//Survey Values
$timestamp = $_POST['timestamp'];
$assigned_1 = $_POST['assigned_1'];
$assigned_2 = $_POST['assigned_2'];
$assigned_3 = $_POST['assigned_3'];
$assigned_priority = $_POST['assigned_priority'];
$approval = $_POST['approval'];
//Connect to database
mysql_connect($server,$username,$password);
@mysql_select_db($database) or die( "Unable to select database");
//Insert values from survey_add.htm variable
$query = "UPDATE request SET assigned_1='$assigned', assigned_priority='$assigned_priority', approval='$approval' WHERE timestamp='timestamp'";
//run query variable
mysql_query($query);
//print errors if any on page
echo mysql_error();
//disconnect from the database
mysql_close();
?>