Extents in Temporary Segments (21)
When Oracle completes the execution of a statement requiring a temporary segment, Oracle automatically drops the temporary segment and returns the extents allocated for that segment to the associated tablespace. A single sort allocates its own temporary segment in a temporary tablespace of the user issuing the statement and then returns the extents to the tablespaces.Multiple sorts, however, can use sort segments in temporary tablespaces designated exclusively for sorts. These sort segments are
Extents in Rollback Segments (20)
Oracle periodically checks the rollback segments of the database to see if they have grown larger than their optimal size. If a rollback segment is larger than is optimal (that is, it has too many extents), then Oracle automatically deallocates one or more extents from the rollback segment.Oracle定期检查会管段是否增长超过它们的optimal size , 假如超过 , Oracle从回滚段中自动回收一个或者多个extents.[@more@]
Extents in Indexes (19)
All extents allocated to an index segment remain allocated as long as the index exists. When you drop the index or associated table or cluster, Oracle reclaims the extents for other uses within the tablespace. 只要索引存在 , 索引段还保留着 . 删除了索引对应的table or cluster后 , 索引段可供表空间内其他用户使用.[@more@]
Extents in Materialized Views and Their Logs (18)
Oracle deallocates the extents of materialized views and materialized view logs in the same manner as for tables and clusters.回收extents的方式和table , cluster相同[@more@]
Extents in Clustered Tables (17)
Clustered tables store information in the data segment created for the cluster. Therefore, if you drop one table in a cluster, the data segment remains for the other tables in the cluster, and no extents are deallocated. You can also truncate clusters (except for hash clusters) to free extents. 在cluster中删除一张表, 数据段还是保留给其他在该cluster中的表 , 除了hash cluster , 可以用truncate clusters来使extents free. [@more@]
Extents in Nonclustered Tables(16)
As long as a nonclustered table exists or until you truncate the table, any data block allocated to its data segment remains allocated for the table. Oracle inserts new rows into a block if there is enough room. Even if you delete all rows of a table, Oracle does not reclaim the data blocks for use by other objects in the tablespace. After you drop a nonclustered table, this space can be reclaimed when other extents require free space. Oracle reclaims all the extents of the table’s data and ind
When Extents Are Deallocated (15)
The Oracle Database provides a Segment Advisor that helps you determine whether an object has space available for reclamation based on the level of space fragmentation within the object.In general, the extents of a segment do not return to the tablespace until you drop the schema object whose data is stored in the segment (using a DROP TABLE or DROP CLUSTER statement). Exceptions to this include the following: ■ The owner of a table or cluster, or a user with the DELETE ANY privilege, can trunc
How Extents Are Allocated(14)
Oracle uses different algorithms to allocate extents, depending on whether they are locally managed or dictionary managed. With locally managed tablespaces, Oracle looks for free space to allocate to a new extent by first determining a candidate datafile in the tablespace and then searching the datafile’s bitmap for the required number of adjacent free blocks. If that datafile does not have enough adjacent free space, then Oracle looks in another datafile.[@more@]
Determine the Number and Size of Extents (13)
A tablespace that manages its extents locally can have either uniform extent sizes or variable extent sizes that are determined automatically by the system. When you create the tablespace, the UNIFORM or AUTOALLOCATE (system-managed) clause specifies the type of allocation. ■ For uniform extents, you can specify an extent size or use the default size, which is 1 MB. Ensure that each extent contains at least five database blocks, given the database block size. Temporary tablespaces that manage t
Export Parameter : Object_Consistent
specifies whether or not the export utility uses the set transaction read onlystatement to ensure that the data exported is consistent to a single point in time anddoes not change during the export. if object_consistent is set to y, each objectis exported in its own read-only transaction, even if it is partitioned. in contrast, ifyou use the Consistent parameter, then there is only one read-only transaction.与Consistent参数的区别:1. Object_Consistent是每个导出的对象都有每个对象的consistent2.
Conventional Path Export Versus Direct Path Export
Export provides two methods for exporting table data:■ Conventional path Export■ Direct path ExportConventional path Export uses the SQL SELECT statement to extract data fromtables. Data is read from disk into a buffer cache, and rows are transferred to theevaluatingbuffer.Thedata,afterpassingexpressionevaluation,istransferredtotheExport client, which then writes the data into the export file.Direct path Export is much faster than conventional path Export because data isread from disk into the
Export Parameter : Consistent
Specifies whether or not Export uses the SET TRANSACTION READ ONLYstatement to ensure that the data seen by Export is consistent to a single point intime and does not change during the execution of theexp command. You shouldspecifyCONSISTENT=y when you anticipate that other applications will beupdating the target data after an export has started.If you useCONSISTENT=n, each table is usually exported in a single transaction.However, if a table contains nested tables, the outer table and each inne
Export Parameter : Compress
Specifies how Export and Import manage the initial extent for table data.The default,COMPRESS=y, causes Export to flag table data for consolidation into one initial extent upon Import. If extent sizes are large (for example, because of thPCTINCREASE parameter), the allocated space will be larger than the space required to hold the data.If you specifyCOMPRESS=n, Export uses the current storage parameters, includin the values of initial extent size and next extent size. The values of the parameter
Export Parameter : Buffer
Specifies the size, in bytes, of the buffer used to fetch rows. As a result, this parameter determines the maximum number of rows in an array fetched by Export.Use the following formula to calculate the buffer size:buffer_size = rows_in_array * maximum_row_sizeIf you specify zero, the Export utility fetches only one row at a time.Tables with columns of typeLONG,LOB,BFILE,REF,ROWID,LOGICALROWID, orDATE are fetched one row at a time.Example: Calculating Buffer SizeThis section shows an example of
Sqlplus查询时不能显示标题栏
select">sys@ora10g>select 1 from dual; 1可是heading明明设置为onshow">sys@ora10g>show headingheading ON原来当pages参数设置为0的时候,标题栏也是显示不出来的.改为其他值后,即可显示.show">sys@ora10g>show pagespagesize 0set">sys@ora10g>set pages 50000select">sys@ora10g>select 1 from dual; 1---------- 1 谢谢yangtingkun指教[@more@]Sqlplus查询时标题栏不能显示
Cardinality
If the number of distinct values of a column is less than 1% of the number of rows in the table, or if the values in a column are repeated more than 100 times, then the column is a candidate for a bitmap index.a bitmap index on this column can out-perform a b-tree index, particularly when this column is often queried in conjunction with other columns.[@more@]
login as sysdba
不管用什么as sysdba,最终都归于以sys用户登录1 conn其他用户conn">sys@ora10g>conn ring/ring as sysdba已连接。show">sys@ora10g>show userUSER 为 "SYS"2 其他用户以sysdba登录sqlplus ring as sysdbaSQL*Plus: Release 10.2.0.1.0 - Production on 星期二 8月 28 23:29:16 2007Copyright (c) 1982, 2005, Oracle. All rights reserved.输入口令:连接到:Oracle Database 10g Enterprise Edition Release 10.2.0.1.0 - ProductionWith the Partitioning, OLAP and Data Mining optionsshow">sys@ora10g&g
关于学习
1 明确学习目的2 制定学习计划3 倾注学习动力4 端正学习态度 5 感受学习乐趣[@more@]
这些天工作上出了点问题
这几天工作上出了点问题,个人觉得有以下方面需要改进:1 权责最好相等2 给与他人及时表扬,关注他人3 一次认真做完一个事4 以专家权来指导下属,以典范权来督促下属行动[@more@]
When Extents Are Allocated(12)
When you create a table, Oracle allocates to the table’s data segment an initial extentof a specified number of data blocks.An incremental extent is a subsequent extent of the same or greater size thanthe previously allocated extent in that segment.For maintenance purposes, the header block of each segment contains a directory ofthe extents in that segment.[@more@]