MrLeche 1 Posted July 12, 2011 Report Share Posted July 12, 2011 Hi, I would like to know how you would select from multiple tables: tableA colx, coly, cola, colb, colc and tableB col1, col2, cola, colb, colc the tables only differ from the first 2 columns of each of them (tables) but I would like to have it SELECT * FROM "both of them" actually the reason for that is I wanted to lay all out in a while() loop, and at the same time paginate it. while tableA consist of older records, time-wise, it will be the first to be "echo-ed", I had problems paginating it if I do not join the query into a single query as opposed to querying tableA, then echo, then query tableB then echo. thanks! Quote Link to post Share on other sites
Antonio Conte 426 Posted July 12, 2011 Report Share Posted July 12, 2011 SELECT * FROM tableA, tableB .... A tips thought; User more descriptive names for your tables and columns. Quote Link to post Share on other sites
MrLeche 1 Posted July 12, 2011 Author Report Share Posted July 12, 2011 SELECT * FROM tableA, tableB .... A tips thought; User more descriptive names for your tables and columns. Sheez, that easy I was googling and resulted to JOINS, LEFT JOINS, ON AS... Thanks, I'll run a quickie. Quote Link to post Share on other sites
Recommended Posts
Join the conversation
You can post now and register later. If you have an account, sign in now to post with your account.
Note: Your post will require moderator approval before it will be visible.