[eluser]Unknown[/eluser]
Hello all
im trying to execute sql statement that retrieve data from two tables that have same column name which is id
to distinguish between the id from t_employees table i added t_employees.id in the where statement but my problem is that it does not appears in the SQL statement,what i write is:
$where=array('t_employees.id'=>$id);
but i still get the follwing error:
A Database Error Occurred
Error Number: 1052
Column 'id' in where clause is ambiguous
SELECT *, `t_employees`.`id` id FROM (`t_employees`) JOIN `t_descriptions` ON `t_descriptions`.`id` = `t_employees`.`t_descriptions_id` WHERE
`id` = '24' ORDER BY `t_employees`.`id` asc
i dont know why it appears id=24 although i add t_employees.id in the where statement
can any body help me
thanks