A more and less proper method for executing subselects with Active Record. - Printable Version +- CodeIgniter Forums (https://forum.codeigniter.com) +-- Forum: Archived Discussions (https://forum.codeigniter.com/forumdisplay.php?fid=20) +--- Forum: Archived Libraries & Helpers (https://forum.codeigniter.com/forumdisplay.php?fid=22) +--- Thread: A more and less proper method for executing subselects with Active Record. (/showthread.php?tid=22872) |
A more and less proper method for executing subselects with Active Record. - El Forum - 09-22-2009 [eluser]ShawnM[/eluser] I'm seeing most people perform subselects by explicitly generating the SQL in a where statement (one example). I looked into a method that enables the developer to create the subselect itself with active record and decided to use the _compile_select() method contained within the database drivers. This has pros and cons, I go over them in this article on my site. http://shawnmccool.com/2009/09/18/using-code-igniters-active-record-class-to-create-subqueries/ A more and less proper method for executing subselects with Active Record. - El Forum - 09-22-2009 [eluser]ronnie_nsu[/eluser] [quote author="ShawnM" date="1253673882"]I'm seeing most people perform subselects by explicitly generating the SQL in a where statement (one example). I looked into a method that enables the developer to create the subselect itself with active record and decided to use the _compile_select() method contained within the database drivers. This has pros and cons, I go over them in this article on my site. http://shawnmccool.com/2009/09/18/using-code-igniters-active-record-class-to-create-subqueries/[/quote] hmm..looks very interesting.thanks for posting. |