Jump to content

MYSQL Update statment not working


Comdemned

Recommended Posts

Hi All,

 

I have a pretty basic mysql update statment that for some reason is not working properley.

<?php
$query = "INSERT INTO apptype (name, description, timeframe, last_modified) VALUES ('$name', '$description', '$timeframe', '$client_id')";
mysql_query($query, $db);
mysql_close($db);
?>

 

Any help would be greatly appricated.

 

Many thanks

Murray

 

Link to comment
https://forums.phpfreaks.com/topic/87162-mysql-update-statment-not-working/
Share on other sites

Sorry I pasted the wrong code.

 

Here is the code that I am having a problem with.

 

<?php
$query = "UPDATE apptype SET name='$name', description='$description' timeframe='$timeframe', last_modified='$client_id' WHERE type_id='$id'";
mysql_query($query, $db);
?>

 

Thanks again

 

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.