CodeIgniter Forums
Best way to build blog tables - 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: Best way to build blog tables (/showthread.php?tid=35029)

Pages: 1 2


Best way to build blog tables - El Forum - 10-18-2010

[eluser]techgnome[/eluser]
Oh, it's still fairly simple... I had to swap out the simple $this->db->get($tablename) for a couple (three) lines to select the fields, one of which included a GROUP_CONCAT (to put all the categories into one field on a single line for each article I'm pulling back) and of course, I had to add two inner joins... in the grand scheme of things, it isn't the most complicated part of the select method (currently I can pull items on any one of 8 fields... or any combination of those fields)... the model itself, is still CRUD simple... it's the logic inside the CRU parts that changed. Now I'm off to clean up the R and U methods with this new piece of data.

-tg


Best way to build blog tables - El Forum - 10-19-2010

[eluser]pixelcoder[/eluser]
Thanks for sharing your experience there,

Guess it will be a similar path to take when working on this method. Have to finish client projects today which is a shame. If only one could GROUP_CONCAT the client work then shift it into a table called FINISHED ^^. Don't if that PSEUDO logic blends though.

Cheers for pointers all.