Oracle模拟业务写入
下面是Oracle模拟业务写入的方法
[oracle@oracle ~]$ sqlplus /nolog
SQL*Plus: Release 10.2.0.1.0 - Production on Wed Jun 3 14:27:02 2020
Copyright © 1982, 2005, Oracle. All rights reserved.
SQL> conn /as sysdba
Connected.
SQL> select name from v$datafile;
NAME
——————————————————————
/software/app/oracle/oradata/orcl/system01.dbf
/software/app/oracle/oradata/orcl/undotbs01.dbf
/software/app/oracle/oradata/orcl/sysaux01.dbf
/software/app/oracle/oradata/orcl/users01.dbf
SQL> select member from v$logfile;
MEMBER
——————————————————————
/software/app/oracle/oradata/orcl/redo03.log
/software/app/oracle/oradata/orcl/redo02.log
/software/app/oracle/oradata/orcl/redo01.log
SQL> show parameter control_files
NAME TYPE VALUE
control_files string /software/app/oracle/oradata/o
rcl/control01.ctl, /software/a
pp/oracle/oradata/orcl/control
02.ctl, /software/app/oracle/o
radata/orcl/control03.ctl
SQL>
Oracle插入时间戳SQL脚本
create table test(datechar char(2000));
begin
for i in 1 … 10 loop
insert into test values(to_char(sysdate,‘YYYY-MM-DD HH24:MI:SS’));
commit;
dbms_lock.sleep(1);
end loop;
end;
/
select max(DATECHAR) from test;