Hi Friends,
I want to display the contact information and the company information of a contact using the following query
SELECT * FROM Contacts LEFT JOIN Employ ON Contacts.id_no = Employ.id_no WHERE Contacts.id_no = '0058654'
This query returns a row.
But the problem is: the fields with identical names are coming properly.
For eg:
I have fields called address1, address2, and address3 in both the tables.
But I get only the address of the Table2 in the array returned using the following steps
$SQL = "SELECT * FROM Contacts LEFT JOIN Employ ON Contacts.id_no = Employ.id_no WHERE Contacts.id_no = '" . $id_no . "'" ;
$result = mysql_query($SQL);
$line = mysql_fetch_array($result, MYSQL_ASSOC);
How can I get the values of the identical fields from both the tables??
Pls help me
Thanks
Ahmad
Hong Kong