CodeIgniter Forums
Trying to pass a variable from one query to another - 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: Trying to pass a variable from one query to another (/showthread.php?tid=22796)



Trying to pass a variable from one query to another - El Forum - 09-20-2009

[eluser]Unknown[/eluser]
i am trying to convert my site over to CI and i cant figure out how to change my query were i would normally put
$query = ("SELECT * tabler WHERE id = ".$otherquery['tablename']." )
to CI's way of coding, any help would be greatly appreciated.


Trying to pass a variable from one query to another - El Forum - 09-22-2009

[eluser]Damien K.[/eluser]
The user guide explains this pretty well. You may want to RTFM.
http://ellislab.com/codeigniter/user-guide/database/index.html


Trying to pass a variable from one query to another - El Forum - 09-22-2009

[eluser]Unknown[/eluser]
Thank you very much i am reading it now, if you could help me or point me in the right direction for something else that would be awsome. i have a paige set up where i have

Date -------
Movie trailers and clips associated with that date ----

Next Date ---
Movie trailers and clips associated with that date ---

Normally with regular php i would just run to while loops to have it print out all the dates and than any movie trailers and clips assoucited with this date than go to the next date and so on.

how would i go about doing this with code-igniter. loops inside of loops seem to not work.