hhmm got big problem with NULL - 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: hhmm got big problem with NULL (/showthread.php?tid=28041) |
hhmm got big problem with NULL - El Forum - 02-28-2010 [eluser]KrizzAngel[/eluser] i have this test code for my DB.. Quote:$this->db->query("select * from tblprof where name='".$this->input->post('name')."' AND section IS NULL"); im always getting "meron" i dont know why.. i already inserted some values on section field of my DB still im getting "meron".. is my constraint correct?? hhmm got big problem with NULL - El Forum - 02-28-2010 [eluser]Armchair Samurai[/eluser] count_all_results() is used for AR queries, not standard DB queries. Try using num_rows(). hhmm got big problem with NULL - El Forum - 02-28-2010 [eluser]KrizzAngel[/eluser] oh tnx.. it worked now |