SQL>
SQL>
SQL> declare
2 v_dt DATE;
3 v_tx VARCHAR2(2000);
4 begin
5 v_dt := to_date('19:40','HH24:MI');
6 v_tx := to_char(v_dt,'YYYY-MM-DD HH24:MI:SS');
7 DBMS_OUTPUT.put_line(v_tx);
8 v_dt := to_date('11-FEB-2006','DD-MON-YYYY');
9 v_tx := to_char(v_dt,'YYYY-MM-DD HH24:MI:SS');
10 DBMS_OUTPUT.put_line(v_tx);
11 end;
12 /
2007-06-01 19:40:00
2006-02-11 00:00:00
PL/SQL procedure successfully completed.
|