Oracle execuation plan same when 2 schemas has the same table name & structure
Hi,
I have the following scenario:
schema HR: has table EMPLOYEES with 1000 rows.
schema SCOTT: has table EMPLOYEES with 100M rows.
both schema has same package with the same structure, "EMP_SECUR", this package has a fuction "CHECK_AUTH" return true or false:
select EMP_SECUR.CHECK_AUTH (p_NAME,p_EMAIL) from dual;
this procedure make a select on EMPLOYEES table to know if the employee allow to login or not:
select * from employees where name = p_name and email = p_email;
how to let the optimizer avoid using the same plan, when the procedure is called from schema SCOTT where the table is very big?!?!?