help!! update mysql problem

Reply

Join Date: Jan 2006
Posts: 2
Reputation: mehrzadsoft is an unknown quantity at this point 
Solved Threads: 0
mehrzadsoft's Avatar
mehrzadsoft mehrzadsoft is offline Offline
Newbie Poster

help!! update mysql problem

 
0
  #1
Jan 8th, 2006
whats wrong with this code?

i'm really confused!

when i use INSERT code insted of UPDATE in my file, every thing is ok. but when i use UPDATE,it doesn't

work!!

UPDATE:
  1. $query = "UPDATE $tblname SET title='$title', desc='$desc', body='$body', time='$time', faday='$faday', famonth='$famonth', fayear='$fayear', fu_show='$fu_show', fu_day='$fu_day', fu_month='$fu_month', fu_year='$fu_year', wshow='$wshow', dshow='$dshow' WHERE id=$id";


INSERT:

HTML Code:
  1. $query = "INSERT into $tblname values '0', '$title', '$desc', '$body', '$time', '$faday', '$famonth', '$fayear', '$fu_show', '$fu_day', '$fu_month', '$fu_year', '$wshow', '$dshow')" OR die(mysql_error());
Reply With Quote Quick reply to this message  
Join Date: Mar 2004
Posts: 1,620
Reputation: kc0arf is a jewel in the rough kc0arf is a jewel in the rough kc0arf is a jewel in the rough 
Solved Threads: 50
Team Colleague
kc0arf kc0arf is offline Offline
Posting Virtuoso

Re: help!! update mysql problem

 
0
  #2
Jan 9th, 2006
Hello,

Check your grant tables to see if you have the update permission.

http://dev.mysql.com/doc/refman/5.0/...ing-users.html

This could be the source of your problem... you might not have the UPDATE permission.

Christian
Reply With Quote Quick reply to this message  
Join Date: Jan 2006
Posts: 2
Reputation: mehrzadsoft is an unknown quantity at this point 
Solved Threads: 0
mehrzadsoft's Avatar
mehrzadsoft mehrzadsoft is offline Offline
Newbie Poster

Re: help!! update mysql problem

 
0
  #3
Jan 9th, 2006
Originally Posted by kc0arf
Hello,

Check your grant tables to see if you have the update permission.

Christian
thanks for your hint
i use EasyPHP 1.6.0.0

i did it
i checked grant tables
i activated it for All actions, all DBs
but still have problem!
یادباد آنکه درونت نظری با ما بود
رقم مــهر تو بر چهره*ی ما پیدا بود-----------------------------------------------------------------
O' what the good days were those, when you was in love with me.
and because of that, my face was full of happiness.Hafiz
Reply With Quote Quick reply to this message  
Join Date: Mar 2005
Posts: 131
Reputation: william_stam is an unknown quantity at this point 
Solved Threads: 2
william_stam's Avatar
william_stam william_stam is offline Offline
Junior Poster

Re: help!! update mysql problem

 
0
  #4
Jan 15th, 2006
  1. UPDATE `adds` SET `client` = 'client1',`TOTALCOST` = 'totalcost' WHERE `ID` =9710

  1. INSERT INTO `adds` ( `ID` , `client` , `colour`)
  2. VALUES (
  3. NULL , 'sda', 'ads');

try like that
Reply With Quote Quick reply to this message  
Reply

This thread is more than three months old.
Perhaps start a new thread instead?
Message:


Thread Tools Search this Thread



About Us | Contact Us | Advertise | DaniWeb | Acceptable Use Policy | RSS Feed

©2003 - 2009 DaniWeb® LLC