mysql UPDATE request not working and driving me crazy!!!


Posted on 16th Feb 2014 07:03 pm by admin

Hi,

I have been stuck on this for ages.

Did you know?Explore Trending and Topic pages for more stories like this.
Quite simply I am trying to update my database with an update command:

Code: $query="UPDATE `spence13_Portfolio`.`skillsList` SET `skillName` = '$newSkillName' WHERE `skillsList`.`ID` =$id";

This doesn't work even though if I change the line to read:

Code: $query="UPDATE `spence13_Portfolio`.`skillsList` SET `skillName` = '$newSkillName' WHERE `skillsList`.`ID` =7";

..then it does work. The variable $id does equal a number and I even use this code to convert it to an integer just incase it's read as a string:

Code: $id = $_POST[skillsListDropDown]; //this is say 7
$id = ((int)$id);

Can anyone please help me.

Thanks
No comments posted yet

Your Answer:

Login to answer
199 Like 35 Dislike
Previous forums Next forums
Other forums

Generate multilayered array from string.
ok so i have a string that looks like this:
Code: [Select]blog:edit_all,delete_all|users:edit_all

MySQL Primary key gap
Alright, so I have a table with 26 entries in it (id, filename, caption) for my image randomiser (ht

How to generate a random array of integers subject to a certain constraint
I am writing a program that asks the user to enter an integer N and then generates a random array of

Track downloads' status
Hello,

I need to make somehow, some system, to track whether downloads are completed or faile

How to validate from 2 possible answers
Hi

I hope somebody can help me with what will probably be really simple, I'm pulling my hair

Multipe Dynamic Controls & AutoPostback Issue
I currently have a need to create many dynamic controls (Example Textboxes) that need to do a PostBa

PHP Game
hy i was wondering what's the best method in order to make some automatic updates in a php game
<

Bandwidth monitoring?
Hi guys,

I need a little information I have written a php app and I occurred to that I need

Parse error: parse error in C:wampwwwlogspagesmembers.php on line 16
I dont see the problem with this, I always get Parse error: parse error in C:wampwwwlogspagesme

Help with looping
I have a comma separated list of colors taken from a database ($ICo) and a directory of images named

Sign up to write
Sign up now if you have flare of writing..
Login   |   Register
Follow Us
Indyaspeak @ Facebook Indyaspeak @ Twitter Indyaspeak @ Pinterest RSS



Play Free Quiz and Win Cash