행위

Parallel 설정

DB CAFE

thumb_up 추천메뉴 바로가기


You disable parallel SQL execution with an

ALTER SESSION DISABLE PARALLEL DML|DDL|QUERY statement.
  • 모든 후속 DML (INSERT, UPDATE, DELETE), DDL (CREATE, ALTER) 또는 조회 (SELECT) 조작은 해당 명령문이 발행 된 후 연속적으로 실행됩니다.
  • 명령문과 연관된 PARALLEL 절 또는 관련된 테이블 또는 연관된 인덱스와 상관없이 직렬로 실행됩니다.

All subsequent DML (INSERT, UPDATE, DELETE), DDL (CREATE, ALTER), or query (SELECT) operations are executed serially after such a statement is issued.

They will be executed serially regardless of any PARALLEL clause associated with the statement or parallel attribute associated with the table or indexes involved.

다음 명령문은 병렬 DDL 명령을 사용하지 않습니다.

ALTER SESSION DISABLE PARALLEL DDL;

병렬 DDL 명령을 사용

You enable parallel SQL execution with an ALTER SESSION ENABLE PARALLEL DML|DDL|QUERY statement. Subsequently, when a PARALLEL clause or parallel hint is associated with a statement, those DML, DDL, or query statements will execute in parallel. By default, parallel execution is enabled for DDL and query statements.

  • ALTER SESSION ENABLE PARALLEL DML | DDL | QUERY 문으로 병렬 SQL 실행을 사용할 수 있습니다.
  • 결과적으로 PARALLEL 절 또는 병렬 힌트가 명령문과 연관되면 해당 DML, DDL 또는 쿼리 명령문이 병렬로 실행됩니다.
  • 기본적으로 DDL 및 쿼리 문에 대해 병렬 실행이 활성화됩니다.

A DML statement can be parallelized only if you specifically issue an ALTER SESSION statement to enable parallel DML: 병렬 DML을 사용하기 위해 ALTER SESSION 문을 특별히 발행 한 경우에만 DML 문을 병렬화 할 수 있습니다.

ALTER SESSION ENABLE PARALLEL DML;

Forcing Parallel SQL Execution 강제로 병렬 SQL 실행

You can force parallel execution of all subsequent DML, DDL, or query statements for which parallelization is possible with the ALTER SESSION FORCE PARALLEL DML|DDL|QUERY statement. Additionally you can force a specific degree of parallelism to be in effect, overriding any PARALLEL clause associated with subsequent statements. If you do not specify a degree of parallelism in this statement, the default degree of parallelism is used. However, a degree of parallelism specified in a statement through a hint will override the degree being forced.

  • ALTER SESSION FORCE PARALLEL DML | DDL | QUERY 문으로 병렬화가 가능한 모든 후속 DML, DDL 또는 쿼리 문을 병렬로 강제 실행할 수 있습니다.
  • 또한 후속 명령문과 연관된 PARALLEL 절을 대체하여 특정 수준의 병렬 처리를 강제로 적용 할 수 있습니다.
  • 이 명령문에서 병렬 처리 수준을 지정하지 않으면 기본 병렬 처리 수준이 사용됩니다.
  • 그러나 힌트를 통해 명령문에 지정된 정도의 병렬 처리는 강제되는 정도를 대체합니다.

The following statement forces parallel execution of subsequent statements and sets the overriding degree of parallelism to 5:

  • 다음 명령문은 후속 명령문의 병렬 실행을 강제 실행하고 대체 병렬 처리 수준을 5로 설정합니다.
ALTER SESSION FORCE PARALLEL DDL PARALLEL 5;

--RAC 인 경우 확인 사항

SELECT * FROM V$PARAMETER
 WHERE NAME IN (
 'parallel_instance_group' --11g R1
,'parallel_force_local'    --11g R2
 );