![]() |
$this->db->update doesn't always work? - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Development & Programming (https://forum.codeigniter.com/forumdisplay.php?fid=23) +--- Thread: $this->db->update doesn't always work? (/showthread.php?tid=34459) |
$this->db->update doesn't always work? - El Forum - 09-30-2010 [eluser]CodeIgniterNewbie[/eluser] In my LAMP application (using CodeIgniter), I have a call to $this->db->update... that generates a SQL like the following: Code: UPDATE `MyTable` SET `MyProcess` = 5 WHERE `Id` = 1 The problem is that this seems to work intermittently -- and I currently have no idea what might be wrong. Is there anything about MySQL I need to know about when trying to update? I'm adding & updating records a lot (but probably no more than one query every 5 seconds). When I run the query in phpMyAdmin, it works fine. Suggestions on how to troubleshoot this? $this->db->update doesn't always work? - El Forum - 09-30-2010 [eluser]Dennis Rasmussen[/eluser] Need to see more code than that. Do you have any functions or statements around that query? If so, do they run when expected? - Use echo(), die(), print() and print_r() to debug near your query. |