If i have this Query:
SELECT tableA.Id, tableB.Id FROM tableA JOIN tableB ON (tableA.bId = tableB.Id)
Now if i try this in php i have some problems:
while($result = mysql_fetch_array(mysql_query(/Query Above/)){
print $result['tableB.Id'];
}
Now i know what you are going to say that i should do my query as:
SELECT tableA.Id AS aId, tableB.Id AS bId
FROM tableA
JOIN tableB ON (tableA.bId = tableB.Id)
and then use: $result['bId']
But the fact is the query is actually like this:
SELECT tableA.*, tableB.* FROM tableA JOIN tableB ON (tableA.bId = tableB.Id)
Is there any way i can get the result in PHP without doing the AS for each individual matching row?
Thanks