Академический Документы
Профессиональный Документы
Культура Документы
Online
Operations
Managed Lock
Priority
Best Practices
Demos
Problem
Statement
Partition SWITCH
Grant
52-DDL
53-SELECT
Wait
54-SELECT
55-SELECT
Session
Lock Queue
Blocking user
transactions killed
Immediately or
specified wait time
MAX_DURATION* =n
minutes]
MAX_DURATION*
MAX_DURATION*
Terminates DDL
(SWITCH/OIR)
*If no blockers, lock granted immediately and the DDL statement will complete
successfully
Benefits
<low_priority_lock_wait>::=
WAIT_AT_LOW_PRIORITY ( MAX_DURATION =
<time>[MINUTES],
}
Syntax
SQL 2012 behavior omit the
new clause or use
WITH (WAIT_AT_LOW_PRIORITY
(MAX_DURATION= 0
minutes,
ABORT_AFTER_WAIT=NONE))
Examples
Grant
52-DDL
53-SELECT
54-SELECT
55-SELECT
Session
Lock Queue
MLP SWITCH/OIR
ABORT_AFTER_WAIT=BLOCKERS all blocking user transactions killed
ALTER ANY CONNECTION server wide permission
Limitations
Only user blocking sessions can be killed
System sessions cause blocking
SPOIR - Benefits
Granularity
Accessibility
Lock Priority
Availability
Resource savings
SPOIR - Syntax
<single_partition_rebuild_index_option> ::=
{
. | ONLINE = { ON [ ( <low_priority_lock_wait> ) ] | OFF
}
}
<low_priority_lock_wait>::=
{
WAIT_AT_LOW_PRIORITY ( MAX_DURATION =
<time>[MINUTES],
ABORT_AFTER_WAIT = { NONE | SELF | BLOCKERS } )
}
Syntax
Example
Best Practices
ABORT_AFTER_WAIT=BLOCKERS
Locking
DDL Transaction