TO_DATE - How do I pass the date and time to the function
312061Mar 8 2006 — edited Mar 8 2006Hi,
I am writing a PL/SQL code. The code has a simple cursor,
For the criteria, I am using a column called 'created' which is a date column, and the to_date function.
I would like to pass the date and time to the to_date fuction as a parameter, date_value, as shown below.
CURSOR opty is
select a.name, a.id
from s_opty a
where a.created > to_date(date_value, 'DD/MM/YYYY HH24:MI:SS');
I've tried declaring a bind variable,
date_value date := '&1'
but no joy.
Any ideas would be welcomed.
Thanks in antcipation
Mukesh