第0章 ORACL 的安装及相关配置
1.scott用户和它的对象维护
SQL> @C:\oracle\product\
2.cmd下Sqlplus 登录
C:\>sqlplus system/password as sysdba
3.Sqlplus 下的登录
SQL> connect scott/password as sysdba
已连接。
4.sqlplus 格式化语句
SQL> set line 150
SQL> col name for a50
5. SQL> host copy C:\*.* D:\
OR
SQL> host ping baidu.com
Pinging baidu.com [220.181.6.184] with 32 bytes of data:
Reply from 220.181.6.184: bytes=32 time=36ms TTL=55
Reply from 220.181.6.184: bytes=32 time=35ms TTL=55
Reply from 220.181.6.184: bytes=32 time=33ms TTL=55
Reply from 220.181.6.184: bytes=32 time=49ms TTL=55
Ping statistics for 220.181.6.184:
Packets: Sent = 4, Received = 4, Lost = 0 (0% loss),
Approximate round trip times in milli-seconds:
Minimum = 33ms, Maximum = 49ms, Average = 38ms
SQL>
6.
SQL> select * from v$controlfile;
STATUS NAME IS_ BLOCK_SIZE FILE_SIZE_BLKS
------- -------------------------------------------------- --- ---------- --------------
D:\DISK3\CONTROL01.CTL NO 16384 430
D:\DISK6\CONTROL02.CTL NO 16384 430
D:\DISK9\CONTROL03.CTL NO 16384 430
SQL>
7.
SQL> shutdown immediate
数据库已经关闭。
已经卸载数据库。
ORACLE 例程已经关闭。
SQL> startup
ORACLE 例程已经启动。
Total System Global Area 612368384 bytes
Fixed Size 1250428 bytes
Variable Size 201329540 bytes
Database Buffers 402653184 bytes
Redo Buffers 7135232 bytes
数据库装载完毕。
数据库已经打开。
SQL>
8.在学习ORACLE的过程中我一直搞不清楚ORACLE的目录结构,在这里我简单介绍以下
ORACLE HOME有点儿类似与JAVA HOME
ORACLE HOME: C:\oracle\product\
C:\oracle\product\
SQL> host dir C:\oracle\product\
驱动器 C 中的卷没有标签。
卷的序列号是 9044
C:\oracle\product\
2009-07-13 22:38 <DIR> .
2009-07-13 22:38 <DIR> ..
2009-07-16 21:43 7,061,504 CONTROL01.CTL
2009-07-16 21:43 7,061,504 CONTROL02.CTL
2009-07-16 21:43 7,061,504 CONTROL03.CTL
2009-07-19 00:37 52,429,312 REDO01.LOG
2009-07-19 00:29 52,429,312 REDO02.LOG
2009-07-19 00:23 52,429,312 REDO03.LOG
2009-08-06 22:58 304,095,232 SYSAUX01.DBF
2009-08-06 22:58 503,324,672 SYSTEM01.DBF
2009-08-06 22:02 20,979,712 TEMP01.DBF
2009-08-06 22:58 26,222,592 UNDOTBS01.DBF
2009-08-06 22:58 5,251,072 USERS01.DBF
11 个文件 1,038,345,728 字节
2 个目录 8,056,373,248 可用字节
SQL>
C:\oracle\product\
C:\oracle\product\
SQL> host dir C:\oracle\product\
驱动器 C 中的卷没有标签。
卷的序列号是 9044
C:\oracle\product\
2009-07-13 22:36 <DIR> .
2009-07-13 22:36 <DIR> ..
2009-07-13 22:36 <DIR> adump
2009-08-06 23:02 <DIR> bdump
2009-07-13 22:36 <DIR> cdump
2009-07-13 22:38 <DIR> dpdump
2009-07-16 21:24 <DIR> pfile
2009-08-06 23:02 <DIR> udump
0 个文件 0 字节
8 个目录 8,034,578,432 可用字节
SQL>