There's no partition elimination in the 2nd explain because this has been submitted using Prepared SQL (':?') while the 1st explain was done with hard-coded literals.
There should be a simple solution to that problem, simply change the datatype of Start_dt and End_dt to a DATE add a default:
Start_date DATE DEFAULT CURRENT_DATE
There's no partition elimination in the 2nd explain because this has been submitted using Prepared SQL (':?') while the 1st explain was done with hard-coded literals.
There should be a simple solution to that problem, simply change the datatype of Start_dt and End_dt to a DATE add a default:
Start_date DATE DEFAULT CURRENT_DATE