CodeIgniter Forums
how to display data from the db in html tables dynamically? - 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: how to display data from the db in html tables dynamically? (/showthread.php?tid=53707)

Pages: 1 2


how to display data from the db in html tables dynamically? - El Forum - 08-05-2012

[eluser]theprodigy[/eluser]
just change your query. Don't use the 'select all' query.
Code:
$this->db->select('column_1, column_2, column_3');
$this->db->get('table');



how to display data from the db in html tables dynamically? - El Forum - 08-05-2012

[eluser]towki[/eluser]
[quote author="theprodigy" date="1344229907"]just change your query. Don't use the 'select all' query.
Code:
$this->db->select('column_1, column_2, column_3');
$this->db->get('table');
[/quote]

but what if i have 50 colomns? just the ID that i dont want to display


how to display data from the db in html tables dynamically? - El Forum - 08-05-2012

[eluser]theprodigy[/eluser]
50 columns in a single table? Or is your query using several joins?

If you have that many columns in a single table, you may want to look at how your database is structured.