Jump to content

is my mysql update syntax correct ?


cyber_alchemist

Recommended Posts

I am bit new to sql so is this correct for updating these fields and its values ?

UPDATE tourDB
                        SET
                         tour_name = '$tour_name', 
                         tour_type = '$tour_type', 
                         nights  = '$nights',
                         overview = '$overview',
                         itinerary = '$itinerary', 
                         inclusions = '$exclusions', 
                         twin_triple_sharing = '$single_occcupancy', 
                         child_with_no_bed = '$child_with_no_bed',
                         inf_below = '$inf_below,'
                         keywords = '$keywords',
                         title = '$title',
                         description = '$description',
                         url = '$url',
                         categories = '$categories'
                         WHERE 
                         tour_id = '$tour_id'

I want to update these where tour_id column has a value of $tour_id

Link to comment
https://forums.phpfreaks.com/topic/283078-is-my-mysql-update-syntax-correct/
Share on other sites

well, if I replace the php variable's with constants, it works...? but other than that , it not working , maybe i have some problem with my php programme ??? what do suggest , by looking the update query ??  I am stuck for 3 hrs working around this problem  :suicide:

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.