I am having trouble with a certain query. The problem is that I am using an INNER JOIN with two tables that both have a column called "id". I want the query to return ALL the column names but in addition I also want table1.id to be returned as id1 and table2.id to be returned as id2 like this:
$query = "SELECT table1.id AS id2, table2.id AS id2 WHERE column = 'blah'";
However, how do I combine that query with a "SELECT *" query to return all the other columns as they are but with the id columns as defined above too? - without having to list out all the columns individually?