Follow along with the video below to see how to install our site as a web app on your home screen.
Note: This feature may not be available in some browsers.
set serveroutput on
declare
rows_updated number;
begin
update s_emp set salary = salary * 1.1 where salary > 1000;
rows_updated := sql%rowcount;
dbms_output.put_line('There were '||rows_updated||' rows_updated.');
end;
/
There were 19 rows_updated.
PL/SQL procedure successfully completed.
SQL> select sysdate from dual;
SYSDATE
---------
26-AUG-04
SQL> select to_char(sysdate,'yyyy-mm-dd hh24:mi:ss') from dual;
TO_CHAR(SYSDATE,'YY
-------------------
2004-08-26 12:36:46
SQL> create table times (b timestamp(4));
Table created.
SQL> insert into times values(systimestamp);
1 row created.
SQL> insert into times
2 values (to_timestamp('2003-12-13 00:56:44.123','yyyy-mm-dd hh24:mi:ss.ff3'));
1 row created.
SQL> select to_char(b,'yyyy-mm-dd hh24:mi:ss.ff3') from times;
TO_CHAR(B,'YYYY-MM-DDHH24:MI:
-----------------------------
2004-08-26 13:26:01.010
2003-12-13 00:56:44.123
SQL> select * from times;
B
---------------------------------------------------------------------------
26-AUG-04 01.26.01.0100 PM
13-DEC-03 12.56.44.1230 AM