dgmuk Posted July 3, 2007 Share Posted July 3, 2007 Hi, I would like to be able to display the results of an sql query in an html table, but the results need to be displayed in three columns, for example: Column 1 Column 2 Column 3 Result 1 Result 2 Result 3 Result 4 Result 5 Result 6 Result 7 Result 8 Result 9 I've tried to find the answers on the internet but i can't find anything that suits my needs! Can anyone help? Link to comment https://forums.phpfreaks.com/topic/58224-solved-displaying-sql-query-results-in-3-column-table/ Share on other sites More sharing options...
trq Posted July 3, 2007 Share Posted July 3, 2007 There is a snippets explaining this in FAQ / Code snippet repository. Link to comment https://forums.phpfreaks.com/topic/58224-solved-displaying-sql-query-results-in-3-column-table/#findComment-288707 Share on other sites More sharing options...
DeathStar Posted July 3, 2007 Share Posted July 3, 2007 SELECT table1.row1,table1.row2,table1.row3,table2.row1,table2.row2,table2.row3,table3.row1,table3.row2,table1.row3 FROM tab1 AS table1, tab2 AS table2, tab3 AS table3 WHERE table1.id='$id' AND table2.id='$id' AND table3.id='$id' I think that is right. Link to comment https://forums.phpfreaks.com/topic/58224-solved-displaying-sql-query-results-in-3-column-table/#findComment-288716 Share on other sites More sharing options...
Recommended Posts
Archived
This topic is now archived and is closed to further replies.