|
课程第19次(2016-05-09星期一):053第1章,实例管理
【上完1Z0-053的第1章】:052课程复习
【1Z0-051】:共10章
【1Z0-052】:共8章
【1Z0-053】:共2章
a.sh:
- #!/bin/sh
- export ORACLE_SID=orcl
- export ORACLE_HOME=/u01/app/oracle/product/11.2.0/dbhome_1
- /u01/app/oracle/product/11.2.0/dbhome_1/bin/sqlplus /nolog<<EOF
- @/home/oracle/a.sql
- EOF
- ~
复制代码
a.sql:
- conn hr/oracle_4U
- select employee_id, salary from employees;
- set serveroutput on
- declare
- v_1 number;
- begin
- select sum(salary) into v_1 from employees;
- dbms_output.put_line('The total salary is '||v_1||'.');
- end;
- /
- exit
- ~
复制代码
initdb3.ora:
db_name=db3
initdb4.ora:
control_files='/u01/app/oracle/oradata/db4/control01.ctl','/u01/app/oracle/oradata/db4/control02.ctl','/u01/app/oracle/oradata/db4/control03.ctl'
db_name=db4
memory_target=1G
db_block_size=8192
undo_tablespace=undotbs1
undo_management=auto
undo_retention=900
db_recovery_file_dest=/u01/app/oracle/flash_recovery_area
db_recovery_file_dest_size=4G
~
|
|