Jump to content

[SOLVED] update query not updating record


vinpkl

Recommended Posts

hi all

 

i m updating my database table with the below code but its not updating.

 

In database field name is "track_id" VARCHAR (60)

 

$track_id=$_REQUEST['track_id'];

if(isset($_REQUEST['submit']))
{

$track_id=$_REQUEST['track_id'];
$qry_trk="update new_order set track_id = '$track_id' where order_id = $id ";
echo $qry_trk;
if(mysql_query(qry_trk))
{
$msg2="tracking id added & updated in database";
}
else
{
$msg2="tracking id not updated";
}

}

 

on echo it displays corect information but it doesnt updates.

update new_order set track_id = 'AS12345678' where order_id = 370 

 

when i insert the above line in sql then it updates corectly but why is it not updating from php code.

 

vineet

Link to comment
https://forums.phpfreaks.com/topic/163328-solved-update-query-not-updating-record/
Share on other sites

Archived

This topic is now archived and is closed to further replies.

×
×
  • Create New...

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.