Active Record - where_in - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived General Discussion (https://forum.codeigniter.com/forumdisplay.php?fid=21) +--- Thread: Active Record - where_in (/showthread.php?tid=35825) |
Active Record - where_in - El Forum - 11-12-2010 [eluser]Unknown[/eluser] I have a complication query Code: SELECT * I couldn't transform it to "Active record query" I tried to use where_in('(news.CateID ,CreatedDate)', '(SELECT CateID, max(CreatedDate) FROM news WHERE Languages = 2'); but couldn't successful Plz help me ! Cheers. Active Record - where_in - El Forum - 11-12-2010 [eluser]Bart Mebane[/eluser] If the sql is complex enough that it's not obvious how to do it with active record, you can just use your own sql instead, like: Code: $query = $this->db->query($sql); Active Record - where_in - El Forum - 11-14-2010 [eluser]Unknown[/eluser] Tks alot Bart Mebane |