Ambiguous behavior of Joins with ON clause

classic Classic list List threaded Threaded
1 message Options
Reply | Threaded
Open this post in threaded view
|

Ambiguous behavior of Joins with ON clause

prabhatkashyap
Hello,

When ever I'm trying to run following query
select * from emp4 left join emp5 on emp4.id=emp4.name;
  it executes successfully.

But when I m trying to run :
select * from emp4 left join emp5 on emp4.id=emp5.name;
It gave error
Error: java.lang.ClassCastException: java.lang.Integer cannot be cast to java.lang.String

Similarly
select * from emp5 join emp4 on emp4.id=emp5.name;
Is working but
select * from emp5 left join emp4 on emp5.id=emp4.name;
Not working

Please confirm.