PHP programming forum. Ask questions or help people concerning PHP code. Don't understand a function? Need help implementing a class? Don't understand a class? Here is where to ask. Remember to do your homework!
$amount is a value passed to the function and is an integer. An error occurs when I execute the query
SQLSTATE[42000]: Syntax error or access violation: 1064 You have an error in your SQL syntax; check the manual that corresponds to your MySQL server version for the right syntax to use near ''2'' at line 2
If i try the code with a value not passed from the function, the query executes and the script does what it's supposed to. I also bound a parameter to see if that might work but I receive the same error. I'm using PHP Version 5.3.8 if that's of any help.
Thanks
“Don’t worry if it doesn’t work right. If everything did, you’d be out of a job.” - Mosher’s Law of Software Engineering