append the test increases nologging

rn
Under normal circumstances
================================================== ==========================
Table space for the remaining 0.71 G

rn
Normal to create the test table
create table test as select * from tttttt where 0 = 1;

rn
Record of the current session's redo size
select s.SID, s.VALUE
from v $ sesstat s, v $ statname t
where s.sid = 16
and s.STATISTIC # = t.STATISTIC #
and t.name = 'redo size'
6 *
SQL> /

rn
SID VALUE
---------- ----------
10 80712300

Insert 5 million to start data

rn
insert into test select * from tttttt where rownum <= 50000

rn
Elapsed: 00:00:17.27

rn
Record of the current redo size

rn
1 select s.SID, s.VALUE
2 from v $ sesstat s, v $ statname t
3 where s.sid = 10
4 and s.STATISTIC # = t.STATISTIC #
5 and t.name = 'redo size'
6 *
SQL> /

rn
SID VALUE
---------- ----------
10 160754480

rn

Table space remaining 0.622802734375

rn
Summary of time: 17 stopwatch space: 0.71-0.62 = 0.09G
redo generated :160754480-80712300 = 80042180

rn
================================================== =======================
create table nologging

rn
Table space remaining 0.716552734375

rn
create table test nologging as select * from tttttt where 0 = 1;

rn
1 select s.SID, s.VALUE
2 from v $ sesstat s, v $ statname t
3 where s.sid = 10
4 and s.STATISTIC # = t.STATISTIC #
5 and t.name = 'redo size'
6 *
SQL> /

rn
SID VALUE
---------- ----------
10 161388232

rn
Insert 5 million to start data

rn
SQL> insert into test select * from tttttt where rownum <= 50000;

rn
50000 rows created.

rn
Elapsed: 00:00:17.34

rn
After the implementation of the redo

rn
SQL> l
1 select s.SID, s.VALUE
2 from v $ sesstat s, v $ statname t
3 where s.sid = 10
4 and s.STATISTIC # = t.STATISTIC #
5 and t.name = 'redo size'
6 *
SQL> /

rn
SID VALUE
---------- ----------
10 241385848

rn
Table space remaining 0.622802734375

rn
Summary of time: 17 stopwatch space: 0.71-0.62 = 0.09G
redo generated :241385848-161388232 = 79997616

================================================== ============
nologging way to build tables, and then used to insert append mode

rn
Table space remaining 0.71649169921875

rn
create table test nologging as select * from tttttt where 0 = 1;

rn
Record of the current redo size
1 select s.SID, s.VALUE
2 from v $ sesstat s, v $ statname t
3 where s.sid = 10
4 and s.STATISTIC # = t.STATISTIC #
5 and t.name = 'redo size'
6 *
SQL> /

rn
SID VALUE
---------- ----------
10 242019668

rn

Insert the beginning of the way to append data 50000
SQL> insert / * + append * / into test select * from tttttt where rownum <= 50000;

rn
50000 rows created.

rn
Elapsed: 00:00:08.31

rn
After the implementation of the redo
1 select s.SID, s.VALUE
2 from v $ sesstat s, v $ statname t
3 where s.sid = 10
4 and s.STATISTIC # = t.STATISTIC #
5 and t.name = 'redo size'
6 *
SQL> /

rn
SID VALUE
---------- ----------
10 242257132

Table space remaining 0.614990234375

rn
Summary of time: 8 stopwatch space: 0.71-0.61 = 0.1G
redo generated :242257132-242019668 = 237464

rn
================================================== ================

rn
Summed up under the test, or table nologging normal mode, the speed and redo of the insert does not have a fundamental impact, basically the same space occupied by

rn
Only used together with the insert table nologging prompted the use of append, the speed can increase, and will redo the emergence of much lower than the first two cases, however, take up some storage space and more!

rn
  • del.icio.us
  • StumbleUpon
  • Digg
  • TwitThis
  • Mixx
  • Technorati
  • Facebook
  • NewsVine
  • Reddit
  • Google
  • LinkedIn
  • YahooMyWeb

Related Posts of append the test increases nologging

  • ProC will select the data on the two-dimensional array

    Examples are as follows: (Over)

  • SQL optimization (4) - Table of the three connections

    Test the following three commonly used connection between the table: Sort - merge connected (sort-merge join, SMJ) Nested loops (nested loop, NL) Hash connection (hash join, HASH) 1. To create the test table SQL> select * from v $ version; BANNER ...

  • SQL optimization (5) - commonly used test hints

    First, the purpose of testing SunnyXu in accordance with the "SQL Performance adjust - summarized," commonly used to test the following four categories of hints: 1. The method of instruction optimizer hints with the aim ALL_ROWS: Based on t ...

  • SQL optimization (6) - nested loop drive source select line

    Under normal circumstances, nested loop drive line source should be chosen small table, or a few lines of the line source, but sometimes, not necessarily. We look at a large table to do the examples of the source line drive. 1. To create a test envir ...

  • SQL optimization (3) - four index

    Test the following four types of index: Unique Index Scan (INDEX UNIQUE SCAN) Index range scan (INDEX RANGE SCAN) Scan the whole index (INDEX FULL SCAN) Express-wide scan index (INDEX FAST FULL SCAN) 1. To create the test table and the only composite ...

  • SQL optimization (1) - full table scan and index the test

    Test Objective: To test CBO and RBO, as well as full table scan than index the situation quickly. 1. To create a test environment SQL> select * from v $ version; BANNER -------------------------------------------------- -------------- Oracle Datab ...

  • Oracle10g with cross-platform endian transfer

    In Oracle10g, the same endianness the first cross-platform file information Oracle will automatically re-evaluated, the conversion is no longer necessary. We watch the following tests: [oracle @ danaly oradata] $ sqlplus "/ as sysdba" SQL * ...

  • An example of the use of TKPROF

    First, view and edit parameters SQL> show parameter max_dump_file_size NAME TYPE VALUE ------------------------------------ ----------- --- --------------------------- max_dump_file_size string UNLIMITED SQL> show parameter user_dump_dest NAME TYPE

  • Diagnosis and principles of order

    SQL> select disk.value "Disk", mem.value "Mem", 2 (disk.value / mem.value) * 100 "Ratio" 3 from v $ sysstat mem, v $ sysstat disk 4 where mem.name = 'sorts (memory)' 5 and disk.name = 'sorts (disk)'; D ...

Leave a Reply

Recent
Recent Entries
Tag Cloud
Random Entries
Latest Comments